Book Image

Node.js Blueprints

By : Krasimir Stefanov Tsonev
Book Image

Node.js Blueprints

By: Krasimir Stefanov Tsonev

Overview of this book

Table of Contents (19 chapters)
Node.js Blueprints
About the Author
About the Reviewers

Exploring the Backbone.js framework

Before starting with the example's application, we should check out the main features of the framework. Sometimes, it's good to know what is going on under the hood. So, let's dive in.

Recognizing the framework dependency

Most of the software that we use nowadays is built on top of other libraries or tools. Normally, they are called dependencies. Backbone.js has only one hard dependency—that's Underscore.js, which is a library full of utility functions. There are functions such as forEach, map, or union for arrays. We can extend an object and retrieve its keys or values. All these are functionalities we need sometimes, but they are missing in the built-in JavaScript objects. So, we should include the library in our page. Otherwise, Backbone.js will throw an error because of the missing functionalities.

Backbone.js works really well with jQuery. It checks whether the library is available and starts using it right away. It's a nice collaboration because we...