Skip to content

Instantly share code, notes, and snippets.

@justinmc
Created February 4, 2013 07:57
Show Gist options
  • Save justinmc/4705499 to your computer and use it in GitHub Desktop.
Save justinmc/4705499 to your computer and use it in GitHub Desktop.
Requirejs config file to get `yeoman build` working with jQuery Mobile and Backbone
###
The main requirejs file
###
require.config
paths:
"jquery": "vendor/jquery.min"
"underscore": "vendor/lodash.min"
"backbone": "vendor/backbone-min"
"jquerymobile": "vendor/jquery.mobile-1.2.0.min"
"jquerymobileConfig": "vendor/jquery.mobile.config"
"toolbarPolyfill": "vendor/jquery.mobile.fixedToolbar.polyfill"
"fastButtons": "vendor/jquery.mobile.fastButtons"
shim:
"backbone":
"deps": ["underscore", "jquery"]
"exports": "Backbone"
"jquerymobileConfig": ["jquery"]
"jquerymobile": ["jquery", "jquerymobileConfig"]
"toolbarPolyfill":
"deps": ["jquery", "jquerymobile"]
"fastButtons":
"deps": ["jquery", "jquerymobile"]
require [
"jquery"
"backbone"
"app"
"jquerymobileConfig"
"jquerymobile"
],
($, Backbone, App) ->
$ ->
App.init()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment