Last active
August 29, 2015 14:05
-
-
Save quickstep25/1db89ba9e0f1fb93adcc to your computer and use it in GitHub Desktop.
JavaScript - IIFE TEMPLATE
- when minified the code variables in scope will be minimized as well.
- ref: http://toddmotto.com/what-function-window-document-undefined-iife-really-means/
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 Functions in JavaScript | |
(function ($, window, document, undefined) { | |
'use strict'; | |
$(document).ready(function () { | |
// .. javascript code here ... | |
}); | |
}(jQuery, window, document)); | |
// WHEN MINIMIZED IT BECOMES ..... | |
!function($,n,t,u){"use strict";$(t).ready(function(){})}(jQuery,window,document); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment