title: How use jQuery Mobile with RequireJS?
body: <pre><code>&lt;script type=&quot;text/javascript&quot; src=&quot;/Scripts/jquery-1.8.2.min.js&quot;&gt;&lt;/script&gt;
  &lt;script type=&quot;text/javascript&quot; src=&quot;/Scripts/jquery.mobile-1.2.0.min.js&quot;&gt;&lt;/script&gt;
  &lt;script type=&quot;text/javascript&quot;&gt;
      console.log(jQuery.mobile !== undefined &amp;&amp; 'good'); // prints 'good'!
  &lt;/script&gt;
  
  &lt;script type=&quot;text/javascript&quot; data-main=&quot;/comp/pages/Index.js&quot; src=&quot;/Scripts/require.js&gt;&lt;/script&gt;
  
  &lt;script type=&quot;text/javascript&quot;&gt;
      console.log(jQuery.mobile !== undefined &amp;&amp; 'good'); // prints 'good'!
  &lt;/script&gt;
  </code></pre>
  <p>But in my <code>Index.js</code>, the <code>jQuery.mobile</code> disappears:</p>
  <pre><code>require([], function (view) {
      console.log(jQuery.mobile === undefined &amp;&amp; 'undefined!'); // prints 'undefined!'
  });
  </code></pre>
  <p>How do I bring <code>mobile</code> back to <code>jQuery</code> ? (I obviously don't care about having <strong>some</strong> <code>mobile</code> in <code>jQuery</code>, but interested in using <code>jQuery Mobile</code> with <code>RequireJS</code>.. just to make it clear..)</p>
  <h2>Edit 1:</h2>
  <p>I tried to add <code>require</code> to Index.js:</p>
  <pre><code>console.log(jQuery.mobile === undefined &amp;&amp; 'undefined!'); // prints 'undefined!'
  require(['/Scripts/jquery-1.8.2.min.js', '/Scripts/jquery.mobile-1.2.0.min.js'],
      function (jQuery,jqm, view) {
  
      console.log(jQuery.mobile === undefined &amp;&amp; 'undefined!'); // prints 'undefined!'
  });
  </code></pre>