4 ms·
If you use node, I'd stick with browserify. RequireJS is nice if you want to load scripts asynchronously, but in reality your code is usually packed to one or t
by stephan83 14y ago
If you use node, I'd stick with browserify. RequireJS is nice if you want to load scripts asynchronously, but in reality your code is usually packed to one or two files so there is no need for the asynchronous part. Plus I dislike the RequireJS syntax, but that's personal taste.
- pfraze 14y agohttp://requirejs.org/docs/node.html http://requirejs.org/docs/node.html I appreciate browserify having the exact same syntax, but RequireJS can do serverside.
- stephan83 14y agoYes 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.
- darklajid 14y agoHelp 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.
- stephan83 14y agoI do keep my code in separate files. But my servers deliver them in a single file using browserify (https://github.com/substack/node-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.