Aliasing the jQuery Namespace
<p>According to jQuery online document, if we want to avoid naming conflict, we could write our script like the followings: </p>

<pre><code>jQuery(document).ready(function($) {
  // Code using $ as usual goes here.
});
</code></pre>

<p>While I feel the following approach much easier to understand:</p>

<pre><code>(function($){ //function to create private scope with $ parameter
    //private scope and using $ without worry of conflict
})(jQuery); //invoke nameless function and pass it the jQuery object
</code></pre>

<p>The first approach seems harder for me to consume. My guess here is (with the first approach) that later on the anonymous function will be called behind the scene which will take <strong>jQuery</strong> as its parameter.</p>

<p>However I am not sure if my thinking is right. Could some one help me with it?
Thank you.</p>
