With the rise of single-page web applications, it became a must to be able to manage the growth and complexity of a JavaScript code base. The same applies to ClojureScript.
In an effort to manage this complexity, a plethora of JavaScript MVC frameworks have emerged, such as AngularJS, Backbone.js, Ember.js, and KnockoutJS, to name a few.
They are very different, but share a few common features:
- Giving single-page applications more structure by providing models, views, controllers, templates, and so on
- Providing client-side routing
- Employing two-way data binding
In this chapter, we'll be focusing on the last goal.
Two-way data binding is absolutely crucial if we are to develop even a moderately complex single-page web application. Here's how it works.
Suppose we're developing a phone book application. More than likely, we will...