Book Review: Functional Programming in JavaScript by Luis Atencio

JavaScript Reviews This post may contain affiliate links. If you buy something we get a small commission at no extra charge to you. (read more)

Good programmers are in greater demand and there’s a need for people who know functional programming. This may be expected with established languages like Java or C++. But it’s only recently that JavaScript entered this field.

Functional Programming in JavaScript is perhaps the absolute best book you can get for learning functional JS programming. You do need a background in JavaScript to understand the syntax, but if you’re familiar with coding you’ll breeze through the contents quickly.

The author Luis Atencio often compares procedural code to functional code so you can learn with side-by-side examples. The book covers best practices and modular development to not only teach you functional programming, but to teach it to you the right way.

Book Contents

This is one of the newer JavaScript books I’ve seen and it’s one of the best that I’ve seen covering functional programming. It has 270 pages with a total of 8 chapters plus an appendix.

The 8 chapters are split into three overarching sections: Think Functionally, Get Functional, and Enhancing your Functional Skills. These sections take you from the ground-up by explaining theory, then practice, then more advanced skills.

Here’s a breakdown of the contents:

  1. Becoming functional
  2. Higher-order JavaScript
  3. Few data structures, many operations
  4. Toward modular, reusable code
  5. Design patterns against complexity
  6. Bulletproofing your code
  7. Functional optimizations
  8. Managing asynchronous events and data

Most of the early examples are very basic where you can copy and paste the code snippets right into your IDE. The further you get into the book the more you’ll be relying on 3rd party libraries for non-native JavaScript functionality.

Functional programming doesn’t require excessive libraries or special commands. It’s just a way of writing code and building your architecture. But the examples in this book help you learn functional programming through more complicated problem/solution methods.

I liked the sections on higher-order functions and monads, both of which are valuable topics that get covered in great detail.

I think Luis does a fantastic job comparing procedural programming to functional programming through code snippets. JavaScript is not usually considered a functional programming language, but it can be used as one in the right context.

Anyone who’s already familiar with JavaScript will have an easy time moving through this book. Functional programming is becoming much more popular and employers are looking to hire developers with this skillset.

If you don’t know anything about JavaScript then I would not recommend starting with this book. Instead try JavaScript: Novice to Ninja which is my go-to recommendation for teaching yourself the basics of JavaScript.

The best part is that once you understand the basics there’s no going back. So you can dive deeper into functional programming and move at your own pace. Luis writes in a way that helps you compare both styles of coding along with OOP examples so that you clearly see the differences.

Pros & Cons

My favorite thing about this book is how it approaches the problem of functional programming.

Luis encourages readers to learn how this works, but also why it’s used and what sort of applications it can be used for. This involves a good mix of theory and practical examples to teach you the best practices of functional programming in JavaScript.

Many chapters also write out how to solve problems in a functional way which is really helpful. This forces you to think about functional programming so that you learn to solve all your future problems in the same fashion.

Speaking technically this book excels and really pushes functional programming from every possible angle.

I did notice a few confusing passages with either typos or improper grammar. This occurred more than a few times, and personally I’m OK to just blow past this stuff. But you may be bothered if you expect perfection from tech publishers(a well-deserved sentiment).

I also think some of the code examples stretch the limits of value vs complexity. The author sometimes covers a topic that breaks into functional programming, but then mentions that the topic is too detailed to be covered in the book. At only 270 pages I would’ve expected Luis to just keep going and cover everything.

I’m not sure if this was done to keep the difficulty level down or if it was Manning’s decision. But either way this book may leave you wanting more detail in some areas.

But if you just need to get started I cannot think of a better guide. This title will hold your hand in the beginning and help you compare procedural code to functional code so that you can see the differences. This really is the best way to introduce yourself to functional JS, or even just functional programming in general.

Also since this is a Manning book you get a free digital version whenever you purchase a copy. This is exclusive to Manning’s titles and I find their stuff usually offers the best bang for your buck.

Who Is This For?

Anyone with experience in JavaScript development should have no trouble getting through this book. The early chapters assume zero knowledge of functional programming, so this can be a way to make JavaScript your very first functional language.

If you already know some functional development in another programming language this is a huge bonus. But you should still understand enough JavaScript to get by.

Similarly I think anyone with an interest in all areas of JavaScript will enjoy this book. Even if you don’t think you have a need for functional programming it doesn’t hurt to attempt this book and see what you can do with it.

People who won’t enjoy this book: devs with zero knowledge of JavaScript.

It is a functional programming book at heart but the concepts are explained using JavaScript. So the concepts may be easy to understand if you know some functional programming in another language.

But if you do not know JavaScript I just don’t think you’ll be able to comprehend this information. It dives into detail quickly and doesn’t wait for you to catch up. If you’re willing to learn JS as you work through the book that’s a possibility but still tricky.

As I mentioned earlier the JS Novice to Ninja book can help you get up to speed with JavaScript quickly. I did a review of that book if you want to check it out before grabbing Functional Programming in JavaScript.

Final Summary

Anyone interested in functional JavaScript or just functional programming in general will adore this title. The author Luis Atencio really knows what he’s talking about. He also knows how to teach it well to someone with little functional experience.

I would highly recommend Functional Programming in JavaScript for any developer willing to attempt this hurdle. If you already know some functional programming you’ll get through the material quickly, but no prior knowledge other than procedural JavaScript is required.

I can’t give it a perfect score just because of the various grammar mistakes and the sporadic levels of detail(some chapters more detailed than others). But putting these minor complaints aside, this is one damn good functional programming book.

Review Rating: 4.5/5


Alex is a fullstack developer with years of experience working in digital agencies and as a freelancer. He writes about educational resources and tools for programmers building the future of the web.