Book Review: Mastering JavaScript Design Patterns

Simon Timms: Mastering JavaScript Design Patterns

In the latest batch of new books from Packt Publishing, Mastering JavaScript Design Patterns by Simon Timms attracted my attention the most and as such warranted my review. Now that I finished the book, I don't regret my decision even a little, the author did a great job and this well written book exceeded my expectations.

I was really glad to see that it's actually more than just a book about design patterns. It does a great job at introducing JavaScript as a language from all aspects. From a brief history of this controversial language it quickly dives into its most important specifics which tend to elude the developers coming from other languages such as Java or C#. This serves as a great way to make the book easier to follow even for those with less experience in JavaScript.

The title makes it clear that the majority of the book is focusing on software design patterns. The first part is dedicated to the well known patterns from the classical "Gang of Four" book, but instead of just rehashing its contents, the author takes a different approach and reevaluates the meaning of the same design patterns in a dynamic language like JavaScript in contrast to the object oriented languages from the original book.

The reading gets even more interesting in the second part, which moves on to the more recent design patterns, grouped into different fields of interest: functional programming, automated testing, user interface, web and messaging. Each and every design pattern is introduced in a broader context, with a discussion of its advantages and drawbacks. Most of them are even accompanied by interesting examples from the lively world of A Song of Ice and Fire. At the very end a couple of words are dedicated to the broader topic of dependency injection, aspect-oriented programming and macros, each one of them deserving a book of its own.

With brief mentions interspersed throughout the book, the author also managed to give an overview of the libraries and tools in the current JavaScript ecosystem, without really favoring any of them. A special place among them is reserved to TypeScript and Traceur, 2 languages which extend the current JavaScript with features from its future version ECMAScript 6, but can be compiled back to valid JavaScript of today.

I can recommend the book not only to JavaScript developers, but also to others who want to refresh or expand their knowledge of design patterns. Learning some JavaScript in the process is just an additional benefit.

The book is available on Amazon and sold directly by the publisher.

Get notified when a new blog post is published (usually every Friday):

If you're looking for online one-on-one mentorship on a related topic, you can find me on Codementor.
If you need a team of experienced software engineers to help you with a project, contact us at Razum.
Copyright
Creative Commons License