Last active
August 29, 2015 13:56
-
-
Save markcarrrr/8997561 to your computer and use it in GitHub Desktop.
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 GLOBAL_NAME = {}; | |
;(function($, window, document){ | |
'use strict'; | |
var PLUGIN_NAME = this.PLUGIN_NAME = function(element, options){ | |
this.element = $(element); | |
this.options = $.extend({}, this.options, options); | |
this.initialise(); | |
}; | |
PLUGIN_NAME.prototype = { | |
options: {}, | |
initialise: function(){ | |
this.FUNCTION_NAME(); | |
}, | |
FUNCTION_NAME: function(){ | |
// DO SOMETHING | |
} | |
}; | |
$.fn.pLUGIN_NAME = function(options){ | |
new PLUGIN_NAME(this, options); | |
return this; | |
}; | |
}).apply(GLOBAL_NAME, [jQuery, window, document]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment