npm install backbone-boilerplate
|2||downloads in the last week|
|14||downloads in the last month|
|Version||1.0.0 last updated 6 months ago|
This boilerplate is the product of much research and frustration. Existing boilerplates freely modify Backbone core, lack a build process, and are very prescriptive; Backbone Boilerplate changes that.
The Backbone Boilerplate is a way of organizing a web application with some opinionated defaults: such as Backbone, Lo-Dash, jQuery, RequireJS, Bower, Grunt, and the HTML5 Boilerplate styles.
Organize your application with a logical file structure, develop your Models/Collections/Views/Routers inside modules, and build knowing you have efficient code that will not bottleneck your users.
Thanks to our Contributors! Special Thanks to: cowboy, iros, nimbupani, wookiehangover, and jugglinmike for helping me create this project. Extra Special Thanks to: Paul Guinan for giving me usage rights to his fantastic Boilerplate character.
View the Backbone Boilerplate documentation here:
The easiest way to get started is to install Git and clone the repository:
# Using Git, fetch only the latest commits. You won't need the full history # for your project. git clone --depth 1 firstname.lastname@example.org:backbone-boilerplate/backbone-boilerplate.git # Move the repository to your own project name. mv backbone-boilerplate my-project
You will need to download and install Node.js if you want to use the commands in the following sections.
Third party packages may update independently from this main repo, so it's a good idea to update after fetching.
# Install Bower. Depending on your user account you may need to gain # elevated privileges using something like `sudo`. npm install -gq bower # Install NPM and Bower dependencies (Bower is hooked up in package.json). npm install -q
The build process consists of numerous Grunt plugin tasks that work together to optimize your application.
# Make sure you install grunt-cli globally. Depending on your user account you # may need to gain elevated privileges using something like `sudo`. npm install -gq grunt-cli # To run the build process, run the default Grunt task. grunt # Run a build and test the now optimized assets. grunt default server:release
To run tests, simply add
.spec.js files throughout your application and they
will be automatically picked up by the runner. You can find example test specs
To run Karma as a daemon: Which will automatically run your tests after you save.
To run Karma tests once and output the results:
After either above command is run, code coverage reports will be available in
By default, the test runner is Mocha and Chai. You can easily change this by
editting the commented regions of the karma configuration in
Copyright © 2013 Tim Branyen (@tbranyen)
Licensed under the MIT license.