Skip to content

Instantly share code, notes, and snippets.

@alarner
alarner / .eslintrc
Last active February 24, 2016 19:53
eslint configuration
{
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
},
},
"rules": {
"quotes": [2, "single"],
# DBLA ZSH Theme borrowed from AVIT
PROMPT='${_current_dir}'
PROMPT2='%{$fg[grey]%}◀%{$reset_color%} '
RPROMPT='$(git_prompt_info)'
local _current_dir="%{$fg[blue]%}%3~%{$reset_color%}: "
@mythz
mythz / xhr.js
Created November 2, 2011 19:05
Standalone jQuery-like Ajax Client
//Adds $.xhr and jQuery-like $.ajax methods to the prescribed namespace.
//Inspired from David Flanagans excellent cross-platform utils http://www.davidflanagan.com/javascript5/display.php?n=20-1&f=20/01.js
//Includes underscore.js _.each and _.extend methods
//modified to behave like jQuery's $.ajax(), not complete.
(function($) {
var win=window, xhrs = [
function () { return new XMLHttpRequest(); },
function () { return new ActiveXObject("Microsoft.XMLHTTP"); },
function () { return new ActiveXObject("MSXML2.XMLHTTP.3.0"); },
function () { return new ActiveXObject("MSXML2.XMLHTTP"); }