Created
June 6, 2019 17:30
-
-
Save whoisryosuke/6754afc11c38022bd3bb8d949fd3c2bb to your computer and use it in GitHub Desktop.
jQuery - IIFE Boilerplate - based on: http://gregfranko.com/blog/jquery-best-practices/
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
// 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