With several hours of road between Vancouver and Tofino, not to mention a couple of ferry boat journeys, I threw two recently published books into my “offline book bag” and started reading.
Though Backbone has been around for almost four years now, it only reached 1.0 status – typically a release that developers consider to be stable enough to support for a while – around this time last year.
As I sat down and sketched out a couple of projects on the horizon that would need to facilitate a fair amount of user interaction with data, I realized that it was time to do some catch-up reading…
Developing a Backbone.js Edge
Many years ago, I made one of the best investments of my business life: A subscription to Safari Books Online. I believe that I get a big return on investment for the $400 that it costs each year – basically, every technical book under the sun at my fingertips. And thanks to the “offline book bag” feature, I can load up the iPad version of the app with my current reading list for Internet-free enjoyment.
The first book I read was by Developing a Backbone.js Edge Bleeding Edge Press (one of the nice things about Safari Online Books is that they’ve got agreements with just about every publisher in the technology books space).
The example app that this book steps through builds on the Github API, which is a nice demonstration of the Backbone approach to working with RESTful resources. This book also explains how to use technologies like localstorage to reduce the HTTP requests or to keep apps responsive in low-bandwidth situations (like ferry boats!).
It was a solid read, but left me wanting more.
The other book I had in my offline book bag was Beginning Backbone.js, published by Apress. This book was published eight months after Developing a Backbone.js Edge, also roughly eight months after the 1.0 release, is about twice is long, and already has some high ratings from reviewers.
Though it covered a lot of the same terrain, this book was particularly well organized and aimed at connecting the Backbone concepts to other familiar patterns in software and Web development. I finished reading it feeling like I had a fuller understanding of where Backbone is positioned in the field of similar library and framework options, and where to go next in terms of the Backbone ecosystem of extensions or with related projects like Marionette.
This book also introduced topics like testing, pre-processing, and so on, but at the end of the book which made more sense to me. The section on best practices, as well as the one on manageable code, where both useful additions.
The complete app example in this book – a Twitter-based application – similarly takes a journey through RESTful concepts, as well as more contemporary example of using localstorage, and then continues to demonstrate how to evolve the application to use Marionette, Thorax, and even RequireJS. Seeing the relationship between Backbone and other libraries and was the real learning in this book for me.
However, the one resource that I found the most exceptionally useful was: Backbone patterns. Specifically, the sections on:
- Conventions: naming, namespaces, and so on.
- Anti-patterns: how to play nice with jQuery and more.
So, there you go, two quick book reviews. Enjoy.
And, while we’re here, let me ask: What are your favourite reads or resources on Backbone.js? Drop them in the comments or send me a note on Twitter.