Skip to content

Instantly share code, notes, and snippets.

@lukemartin
Created July 8, 2011 06:49
Show Gist options
  • Save lukemartin/1071270 to your computer and use it in GitHub Desktop.
Save lukemartin/1071270 to your computer and use it in GitHub Desktop.
JavaScript: jQuery plugin template
(function ($) {
$.fn.droppie = function (options) {
// override options
var opts = $.extend({}, $.fn.plugin.defaults, options);
return this.each(function() {
$.fn.plugin.something();
});
};
$.fn.plugin.something() = function() {
};
$.fn.plugin.defaults = {
};
}(jQuery));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment