Skip to content

Instantly share code, notes, and snippets.

@whoisryosuke
Created June 6, 2019 17:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save whoisryosuke/6754afc11c38022bd3bb8d949fd3c2bb to your computer and use it in GitHub Desktop.
Save whoisryosuke/6754afc11c38022bd3bb8d949fd3c2bb to your computer and use it in GitHub Desktop.
jQuery - IIFE Boilerplate - based on: http://gregfranko.com/blog/jquery-best-practices/
// IIFE keeps all code out of global scope
(function($, window, document) {
// The $ is now locally scoped
$(function() {
// The DOM is ready!
// equiv of $(document).ready(function () {
});
}(window.jQuery, window, document));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment