Skip to content

Instantly share code, notes, and snippets.

@designeng
Created March 14, 2014 18:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save designeng/9554206 to your computer and use it in GitHub Desktop.
Save designeng/9554206 to your computer and use it in GitHub Desktop.
processRouteMap = (routes) ->
requirejs.config
nodeRequire: require
paths:
"routeMap" : __dirname + "/../../../app/js/" + "routeMap"
"requireConfig" : __dirname + "/../../../app/js/" + "requireConfig.js"
"text" : __dirname + "/../../../app/js/vendors/requirejs-text/text"
requirejs ["routeMap", "text!requireConfig"], (routeMap, requireConfig) ->
console.log "requireConfig", requireConfig
getRoutesModules routeMap, routes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment