javascript - RequireJS config loading individual modules when they're already included in global module -


alright, i've got multi-page site page-specific modules. each page should load 2 js files generated r.js: main.js, collection of modules available globally, , "page-name-here".js, collection of modules needed current page.

i tried pattern off of response similar question: https://stackoverflow.com/a/11730147/843490.

i wanted structure wouldn't have explicitly include jquery dependency in every module, loaded , executed first.

build.js file: http://pastebin.com/xp2cch18 main.js file: http://pastebin.com/vsanm99s

the r.js tool seems compiling correctly modules written main.js , "page-name-here".js. but, when load page, require js starts bringing in every global module individually after main.js has loaded. assume due global.js not being listed explicitly dependency, i'm unsure of have tweak remedy this.

any clues? thanks!


Comments

Popular posts from this blog

node.js - Bad Request - node js ajax post -

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -