What is the use of backbone.js in structuring javascript?

Backbone is an MVC framework for the frontend. With Backbone, you represent data as Models, which can be created, validated, destroyed, and saved to the server. Whenever a UI action causes an attribute of a model to change, the model triggers a "change" event; all the Views that display the model's state can be notified of the change so that they are able to respond accordingly, re-rendering themselves with the new information.

Backbone gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.

You don't need to tie your models to the DOM manually, backbone takes care of that and makes making changes easier for better developer experience.

Updated on: 27-Nov-2019


Kickstart Your Career

Get certified by completing the course

Get Started