Re:RequireJS 2.0 draft
by stephan83 on Tuesday May 01, 2012 @11:19AM
(#3914733)
Yes but as I said I don't need async loading of scripts, since all my code is packed in usually a single file. Therefore I don't need the RequireJS syntax, and I'd rather stick with a simple require syntax.
[ Parent
| on HN ]
Help me, I'm still fumbling around in the web world und miss a lot.
Why would you even look at require.js if you don't have modular code/code of your own spread over a couple of files? This is for me the one single reason to look into it in the first place. To organize my own code better.
I do keep my code in separate files. But my servers deliver them in a single file using browserify (https://github.com/substack/node-browserify).
It's great thing that you use RequireJS to organize your code, and you should keep doing it. We use RequireJS at work and it works pretty well. However my personal preference is browserify, but use whatever works for you.