Skip to content

Instantly share code, notes, and snippets.

@kuznetsovandrey76
Created October 8, 2018 13:19
Show Gist options
  • Select an option

  • Save kuznetsovandrey76/7c544baa54a3042f4976389feef82c6e to your computer and use it in GitHub Desktop.

Select an option

Save kuznetsovandrey76/7c544baa54a3042f4976389feef82c6e to your computer and use it in GitHub Desktop.
jQuery plugin
(function( $ ) {
$.fn.myPlugin = function() {
// Тут пишем функционал нашего плагина
$(this).click(function(){
$(this).css('color', '#ff0000');
})
// ===================================
};
})(jQuery);
$('p').myPlugin()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment