Created
March 14, 2013 02:26
-
-
Save robdodson/5158317 to your computer and use it in GitHub Desktop.
require
This file contains hidden or 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
| define(['require', 'jquery'], function(require, $) { | |
| $(function() { | |
| // do a buncha stuff with jquery on document load... | |
| // later on... | |
| require(['d3'], function(d3) { | |
| // now it's loaded d3 | |
| }); | |
| }); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment