This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var a = (new Array).constructor, | |
d = (new Date).constructor, | |
r = (new RegExp).constructor; | |
function realTypeOf(v) { | |
var t = typeof(v); | |
if (t == "object") { | |
if (v === null) return "v"; | |
switch (v.constructor) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var zep = "__proto__" in window; | |
yepnope([{ | |
test: zep, | |
yep: '/static/js/zepto.js', | |
nope: '//ajax.googleapis.com/ajax/libs/jquery/1.8.1/jquery.min.js', | |
complete: function () { | |
!zep && !window.jQuery && yepnope('/static/js/jquery-1.8.1.min.js'); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* @group Base */ | |
.chzn-container { | |
font-size: 13px; | |
position: relative; | |
display: inline-block; | |
zoom: 1; | |
*display: inline; | |
} | |
.chzn-container .chzn-drop { | |
background: #fff; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Text = (function () { | |
var R = /[\.,-\/#!$%\^&\*;:{}=\-_`~()\s]/; | |
function parse(str, wordTemplate, wrapTemplate) { | |
var count = 0, | |
output = "", | |
e, | |
sub; | |
// add a space to the end so we always see the last word |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var MrButtlertron = (function () { | |
return { | |
query: function (selector, scope) { | |
return (scope || document).querySelectorAll(selector); | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function blatFalse(o) { | |
var output = {}; | |
for (var key in o) { | |
if (o.hasOwnProperty(key)) { | |
var val = o[key]; | |
if (o[key].constructor == Object) { | |
output[key] = blatFalse(val); | |
} else { | |
if (o[key] && typeof val !== "function") output[key] = val; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Observable (o) { | |
var data = o; | |
var hasChanged = function (o) { | |
if (o !== data) { | |
return true; | |
} | |
if (JSON.stringify(o) !== JSON.stringify(data)) { | |
return true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FnModifier = (function () { | |
var o = {}; | |
function isFunction (fn) { | |
return fn && o.toString.call(fn) == "[object Function]"; | |
} | |
var args_r = /^function\s*[^\(]*\(\s*([^\)]*)\)/m; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function () { | |
var table = $('#some-table'); | |
var initOptions = { | |
}; | |
function decode(s) { | |
return JSON.parse(decodeURIComponent(s)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ $# == 0 ] | |
then | |
exit 0 | |
fi | |
DIR=$1 | |
FILE="lol.txt" | |
DAYS=( "Monday" "Tuesday" "Wednesday" "Thursday" "Friday" "Saturday" ) |