Skip to content

Instantly share code, notes, and snippets.

@mkuklis
Last active December 12, 2015 04:18
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save mkuklis/4712839 to your computer and use it in GitHub Desktop.
Save mkuklis/4712839 to your computer and use it in GitHub Desktop.
requirejs+flight
// requirejs config in main.js
require.config({
paths: {
jquery: 'components/jquery/jquery',
es5shim: 'components/es5-shim/es5-shim',
es5sham: 'components/es5-shim/es5-sham'
},
map: {
'*': {
'flight/component': 'components/flight/lib/component',
}
},
shim: {
'components/flight/lib/index': {
deps: ['jquery', 'es5shim', 'es5sham']
},
'app/js/app': {
deps: ['components/flight/lib/index']
}
}
});
require(['app/js/app'], function (App) {
App.initialize();
});
@mkuklis
Copy link
Author

mkuklis commented Feb 5, 2013

for layout:

▾ app/
▸ css/
▾ js/
app.js
▾ components/
▸ es5-shim/
▸ flight/
▸ jquery/
▸ requirejs/
index.html
main.js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment