Skip to content

Instantly share code, notes, and snippets.

David DeSandro desandro

Block or report user

Report or block desandro

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View twitter-less.css
/* sidebars */
.Trends,
.wtf-module,
.RelatedUsers,
.SignupCallOut,
/* in timeline */
.wtf-module.has-content,
.tweet.dismissable-content,
.LiveVideoHomePageModuleContainer,
.WtfLargeCarouselStreamItem, /* WTF in timeline */
View get-style-property.js
/*!
* getStyleProperty by kangax
* http://perfectionkills.com/feature-testing-css-properties/
*/
/*jshint browser: true, strict: true, undef: true */
( function( window ) {
'use strict';
@desandro
desandro / jquery.imagesloaded.js
Created Jan 26, 2011 — forked from paulirish/README.md
$.fn.imagesLoaded jQuery plugin
View jquery.imagesloaded.js
// $('img.photo',this).imagesLoaded(myFunction)
// execute a callback when all images have loaded.
// needed because .load() doesn't work on cached images
// Modified with a two-pass approach to changing image
// src. First, the proxy imagedata is set, which leads
// to the first callback being triggered, which resets
// imagedata to the original src, which fires the final,
// user defined callback.
View candy-box-cheats.js
// http://candies.aniwey.net/
// enter in console
candies.nbrOwned = Number.POSITIVE_INFINITY;
lollipops.nbrOwned = Number.POSITIVE_INFINITY;
quest.setMaxLandOrder( 20 );
chocolateBars.nbrOwned = 10;
sword.specialPower = 100;
for ( var potionName in potions.list ) {
View README.md
View bower-logo.md

In addition to awesome docs #228, Bower deserves a proper logo. See below for sketches. I'm curious if you think any of these are worth me putting more effort into.


Take a look at Yeoman right now.

Screen Shot 2013-02-19 at 4 43 10 PM

The other two entities have awesome logos. Bower's got to represent.

@desandro
desandro / halftone-cartesian.pde
Last active Nov 1, 2018
Half-ton halftones Processing sketch
View halftone-cartesian.pde
// options
String imagePath = "img/desandro-avatar.jpg";
float res = 10; // resolution, dot density
float zoom = 3.0; // proportion to zoom image
boolean isAdditive = true; // true = RGB, false = CMY
float offsetAngle = 1; // affects dot pattern
/*
0 = no patter
0.05 = slight offset
1 = slight offset
@desandro
desandro / require-js-discussion.md
Created Jan 31, 2013
Can you help me understand the benefit of require.js?
View require-js-discussion.md

I'm having trouble understanding the benefit of require.js. Can you help me out? I imagine other developers have a similar interest.

From Require.js - Why AMD:

The AMD format comes from wanting a module format that was better than today's "write a bunch of script tags with implicit dependencies that you have to manually order"

I don't quite understand why this methodology is so bad. The difficult part is that you have to manually order dependencies. But the benefit is that you don't have an additional layer of abstraction.


View twitter-nix.css
/* sidebars */
.Trends,
.wtf-module,
.RelatedUsers,
.SignupCallOut,
/* in timeline */
.wtf-module.has-content,
.tweet.dismissable-content,
.LiveVideoHomePageModuleContainer,
.WtfLargeCarouselStreamItem, /* WTF in timeline */
View inclusion-rider-response.md

Hello █████,

Thanks for getting in touch and for this tremendous invitation. I'm flattered and excited by the offer.

Representation matters to me. I'm curious: How are you aiming to build a diverse speaker line-up this year? Last years's conference only had 1 female and 1 person of color.

My inclusion rider: I'll join as a speaker if the line-up includes at least ██ women and ██ POC.

I realize putting together a diverse line-up is difficult. As a white male, I'd rather not take up a slot that could better feature someone not like me. Here's a list of people I can recommend.

You can’t perform that action at this time.