Skip to content

Instantly share code, notes, and snippets.

View amadeusjunqueira's full-sized avatar

amadeusjunqueira

View GitHub Profile
@amadeusjunqueira
amadeusjunqueira / jquery.demo-plugin.js
Created August 1, 2011 20:00 — forked from zhannes/jquery.demo-plugin.js
A cleaner approach to jquery plugins. Separate the code for the plugin's functionality from the assignment into the jQuery namespace. Taken from various articles/presos by Alex Sexton and Paul Irish, and #jquery IRC chats. With enthusiasm for Object.creat
(function( $ ){
/*
A cleaner approach to jquery plugins. Separate the code for the plugin's functionality from
the assignment into the jQuery namespace.
Taken from various articles/presos by Alex Sexton and Paul Irish, and #jquery IRC chats.
With enthusiasm for Object.create() toned down after http://news.ycombinator.com/item?id=2594521
*/