using requireJS to manage dependencies, and r.js to optimize