title: Best Practices to add 3rd party jQuery plugins to requireJS?
body: <p>Say for example, someone wrote a great jQuery plugin that I want to use on my site, but it's non-AMD. How do I add it to requireJS? For demo purposes, pretend this plugin is called "codeFormatter" and it takes any <code>&lt;pre&gt;</code> tag and formats it such that each line gets indices. And obviously, codeformatter need jQuery to work. </p>
  
  <p>Let's say before adding codeFormatter, there's a <code>&lt;pre&gt;</code> section on my page that looks like this:</p>
  
  <pre><code>var foo = function() {
      console.log("foo");
  }
  </code></pre>
  
  <p>And let's say this jQuery codeformatter is called and fired (traditionally) via:</p>
  
  <pre><code>&lt;script src="scripts/lib/jquery.js"&gt;&lt;/script&gt;
  &lt;script src="scripts/codeformatter.js"&gt;&lt;/script&gt;
  &lt;script&gt;
      $("pre").codeFormatter();
  &lt;/script&gt;
  </code></pre>
  
  <p>After adding codeFormatter:</p>
  
  <pre><code>1. var foo = function() {
  2.     console.log("foo");
  3. }
  </code></pre>
  
  <p>Anyway, since this codeFormatter.js plugin is maintained by someone else remotely, such as being stored on github, there's no point in me copying the code and then using the <code>define()</code> method.</p>
  
  <p>What is the best practice for putting codeFormatter.js into requireJS with shim or define or require, etc?</p>