 <p>You can access faster to local vars, also you can shorten the variable name "window" (and even "document") with something like:</p> <pre><code>(function(w, d)(){ // use w and d var })(window, document) </code></pre>