Thanks for clearing that up. I'll update it if the CSP I'm targeting doesn't like it. So far its just a distributed prototype that'll sit there and wait for its test run.
Code Protection isn't the goal either or I would have said that in the documentation. All it's supposed to do is scramble code to a degree thats necessairy for the targeted plattform not getting suspicious.
Since the code is also only run in on a page that is so laden with JS before and after it, I feel like it doesn't necessairly matter that much.
This is currently still a prototype and I'm looking for people to review it and if it would be a viable addition to the wealth of npm packages on npmjs.org .
So please if you like or dislike something about the idea please discuss it here or on the repository.
RequireJS with code split up between several sources is good and okay during the development phase. When you go from dev to production you can let r.js combine them for you in order to get your pipeline.
See:
http://requirejs.org/docs/optimization.html
and:
http://requirejs.org/docs/node.html
This way you have compiled, minified code that can got into production systems.
Besides, having the server do asset-pipelining during runtime may be unnecessary overhead on the systems circumvented by pre-minification and compression through tools like r.js