concept backbone.js in category jQuery

appears as: Backbone.js
jQuery in Action, Third Edition

This is an excerpt from Manning's book jQuery in Action, Third Edition.

Finally, in the last section of this chapter, we’ll take a look at Backbone.js. The section isn’t meant as a complete guide to this framework, but we want to give you an idea of what’s next in your learning path and how jQuery integrates with frameworks such as Backbone.js to create complex applications.

Figure 15.4. A schema of how a router interacts with other components of Backbone.js

The structure of the project, shown in figure 15.6, is quite straightforward. It has an index.html page that contains the HTML markup and the templates used by the application. It also has a css folder containing the basic CSS file that gives the application a better look and feel, a js folder containing all the libraries included (such as jQuery and Backbone.js) inside a subfolder named vendor, and a file called app.js containing the project’s specific code. To keep things as easy as possible, you’ll put all the code in the same file, but when dealing with large projects a better choice is to have a different file for every object stored in a subfolder named like the components you’ve seen so far: models, collections, and views.