News for hackers. Stuff that matters.
Re:RequireJS 2.0 draft by stephan83 on Tuesday May 01, 2012 @10:53AM (#3914580)
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.
Re:RequireJS 2.0 draft by pfraze on Tuesday May 01, 2012 @11:01AM (#3914622)
http://requirejs.org/docs/node.html

I appreciate browserify having the exact same syntax, but RequireJS can do serverside.

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.
Re:RequireJS 2.0 draft by darklajid on Tuesday May 01, 2012 @12:24PM (#3915096)
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.

Re:RequireJS 2.0 draft by stephan83 on Tuesday May 01, 2012 @12:40PM (#3915180)
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.