Created
April 16, 2013 14:40
-
-
Save Plou/5396460 to your computer and use it in GitHub Desktop.
RequireJs use
This file contains 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
{ | |
"name": "euralille", | |
"version": "0.0.0", | |
"dependencies": { | |
"jquery": "1.9.1", | |
"requirejs": "2.1.5", | |
"underscore": "1.4.4", | |
"modernizr": "2.6.2" | |
}, | |
"devDependencies": {} | |
} |
This file contains 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
<script data-main="typo3conf/ext/skin/template/js/main-min" src="typo3conf/ext/skin/template/js/components/requirejs/require.js"></script> |
This file contains 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
require.config({ | |
shim: { | |
modernizr: { | |
exports: 'Modernizr' | |
}, | |
underscore: { | |
exports: '_' | |
}, | |
base: { | |
deps: ["jquery"] | |
} | |
}, | |
paths: { | |
modernizr: './components/modernizr/modernizr', | |
jquery: './components/jquery/jquery', | |
underscore: './components/underscore/underscore', | |
base: './components/inouit/base' | |
} | |
}); | |
require([ | |
'jquery', | |
'underscore', | |
'modernizr', | |
'base' | |
], function ($, _, Modernizr) { | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment