Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (function($){
- $.fn.pluginName = function(options){
- var settings = {
- myFunction : function(){
- // If specified will allow the user to override it.
- }
- };
- if (options) {
- $.extend(settings, options);
- }
- };
- });
- // Will use default
- $('selector').pluginName();
- // Override
- $('selector').pluginName({
- myFunction : function(){
- // overrides default
- }
- });
Add Comment
Please, Sign In to add comment