Review of Learning Dojo

by jon on April 23, 2009

Recently, Packt contacted me about doing a review of Learning Dojo.

Learning Dojo by Peter SvennsonThe author, Peter Svennson, is probably one of the most qualified people in the world to be writing a book about Dojo, considering he's a contributor. The book takes plenty of time covering some of the more common Dijits and how best to apply them in an application. Like any framework, knowledge of certain core components helps when extending that knowledge across the rest of the library.

As someone who's worked extensively with JQuery and Prototype, I appreciated the authors recognition of other frameworks, while being able to diplomatically keep the discussion focused on Dojo without diminishing the work done on the other site of the Javascript framework fence.

Before being totally entrenched in the various Dojo libraries, Svennson takes a couple pages to explain closures and Javascript's prototype based object model. I found his explanation enlightening and a good starting point for a conversation on Dojo. Svennson also sold me on Dojo's class building framework.

What kept me flipping through the pages was Svennson's passion for the technology. The writing style is informal and conveys his personal interest in Dojo's architecture. However sometimes I felt this same passionate writing starts to read more like a sales pitch and less like a serious technical reference.

If you're the type of person that likes to work through a practical application of the technology, Learning Dojo is probably not the best book for the job. Instead of figuring out how to build a form with client-side validation that showcases all the Dojo bells and whistles (which I don't think one app could truly do), you're invited to create custom events, learn how to build class structures with pseudo-inheritance, look at localization and ways of theming your application. Since a lot of these features are design-releated, they tend to feel disjoint.

Only in the last chapter are we introduced to "real-world Dojo". While the examples are great, they feel almost tacked on. Regardless, the multi-charting project and the CRUD application cover a lot of components that were already discussed previously. It's also nice to see that Svennson mentions how to unit test using DOH. Learning Dojo is by no means a book for beginners: as the book progresses, there are large chunks of markup that are loosely explained in passing.

If you're already married to Dojo, planning a site in Dojo or inheriting something written in Dojo, this book could be a great reference for getting familiar with the technology quickly. If this sounds like you, grab a copy from Amazon.

UPDATE: enjoy reading Chapter 6 for free online!

Leave a Comment

Previous post:

Next post: