"Boilerplate", as I understand it, is text you copy and paste, and then edit to your needs. But the name of the game in programming is "don't repeat yourself", that is, don't copy and paste text. (And "eliminate dependencies," but that doesn't come into play here.)<p>So, in programming, boilerplate is always bad. Boilerplate is the enemy. Boilerplate is what makes software unmaintainable. Boilerplate multiplies bugs. Boilerplate is not a "best practice". Boilerplate is a worst practice. Boilerplate is not canonical; it is demonical. Boilerplate is the failure to factor your software into reusable subroutines. Boilerplate mixes your green, red, and yellow code all together.<p>This seems to be a combination of a decent development environment (a reasonable selection of libraries: Underscore, jQuery, Backbone, node.js) and 1000+ lines of actual boilerplate.<p>I don't know why people here seem so willing to forgive the use of boilerplate. This post has 193 upvotes as I write this so I guess there are at least 193 non-hackers reading and voting on Hacker News. I hope I never have to fix their code.
Might also want to check out my company's bones framework: <a href="https://github.com/developmentseed/bones" rel="nofollow">https://github.com/developmentseed/bones</a><p>Expressjs + Backbone, with plugins, multi-process servers, settings management, etc. It's used by large applications like our hosting service: <a href="http://tiles.mapbox.com/" rel="nofollow">http://tiles.mapbox.com/</a>
This looks fantastic, especially with the integration with HTML5BP. Awesome work!<p>Just wondering if you considered using RequireJS instead of namespacing? Backbone plays quite nicely with RequireJS if you use James Burke's version which has been forked to be compatible: <a href="https://github.com/jrburke/backbone/blob/optamd/backbone.js" rel="nofollow">https://github.com/jrburke/backbone/blob/optamd/backbone.js</a><p>More info here: <a href="http://jcreamerlive.com/2011/12/09/backbonejs-modular-app-using-requirejs/" rel="nofollow">http://jcreamerlive.com/2011/12/09/backbonejs-modular-app-us...</a>
I'd be curious to hear someone from Bocoup describe how this boilerplate fits in when you're already using a web framework.<p>In Rails, or Django, or whatever, wouldn't you want to use the built-in JavaScript folder structure and asset building strategy?
Here's my boilerplate for GAE + Backbone.js + Require.js, which is very good for large scale Javascript development.<p><a href="https://github.com/ronreiter/webapp-boilerplate" rel="nofollow">https://github.com/ronreiter/webapp-boilerplate</a><p>I've seen your source code, and your build directory makes a lot of sense. I'll add it to my boilerplate as well.<p>Thanks for your code!
Glad there are people spearheading discussions around backbone project organization.<p>I agree that backbone is very powerful, but talk is just beginning on how to fit it in to current web app projects that don't fit the boostrapped-singled-html page model
Without getting into the technicalities of this, I am grateful somebody came up with this. I am working on a backbone + jq + mongo app right now & this might have been useful, at least in the early days.
This has been very helpful for me, learning Backbone.js: <a href="http://ricostacruz.com/backbone-patterns/" rel="nofollow">http://ricostacruz.com/backbone-patterns/</a>