Skip to content

Instantly share code, notes, and snippets.

Avatar

Jennifer Culp JustJenFelice

View GitHub Profile
@JustJenFelice
JustJenFelice / util.js
Created Oct 22, 2012 — forked from pamelafox/util.js
JavaScript Utility Libraries (Scroll down!)
View util.js
var ED = ED || {};
// Utility functions
ED.util = (function() {
// Data structure functions
function each(object, callback) {
if (object === null) return;
View jquery.elementQuery.js
// call elementQuery and pass it an object containing the tests.
// also pass it an object containing a 'passed' callback and a 'failed' callback
// you can also pass a bool for whether you want to bind this to be run on resize
$('#torso').elementQuery({ 'min-width' : 910 , 'max-width' : 1155}, {
passed : function() {
$(this).addClass('l-full').removeClass('l-xlarge');
},
failed : function() {
$(this).removeClass('l-full');
View jquery.elementQuery.js
// call elementQuery and pass it an object containing the tests.
// also pass it an object containing a 'passed' callback and a 'failed' callback
// you can also pass a bool for whether you want to bind this to be run on resize
$('#torso').elementQuery({ 'min-width' : 910 , 'max-width' : 1155}, {
passed : function() {
$(this).addClass('l-full').removeClass('l-xlarge');
},
failed : function() {
$(this).removeClass('l-full');
@JustJenFelice
JustJenFelice / db.sh
Created Apr 13, 2012 — forked from johnjosephhorton/db.sh
Bash script to move a file to your public dropbox folder and copy the url to the clip board
View db.sh
#!/bin/bash
cp $1 ~/Dropbox/Public/
echo "http://dl.dropbox.com/u/<your id>/"$1 | xclip -i -selection clipboard