I recently read this, worked through the examples, and was pleasantly surprised at the depth and quality. Subsequently we recommended it to our 800+ member meetup group as the top learning resource for new JS programmers. The content is enlightening and enjoyable and could be just the thing for reaching a breakthrough in understanding about functional programming.
It's also worth mentioning Lodash[1] if you're new to this idea of functional programming. They have an awesome description of each function name and they're very closely aligned to the functional terminology.<p>[1] - <a href="http://lodash.com/docs" rel="nofollow">http://lodash.com/docs</a>
I love this book for it's, ah, eloquent and inclusive way of describing more advanced JS topics. Definitely of value, even for the more experienced JS dev.
On the topic of functional JavaScript, a few interesting articles and books I have been reading that have helped shed more light on this subject matter. I particularly enjoyed the Functional JavaScript book [2].<p>[1] - <a href="http://www.cse.chalmers.se/~rjmh/Papers/whyfp.pdf" rel="nofollow">http://www.cse.chalmers.se/~rjmh/Papers/whyfp.pdf</a><p>[2] - <a href="http://shop.oreilly.com/product/0636920028857.do" rel="nofollow">http://shop.oreilly.com/product/0636920028857.do</a><p>[3] - <a href="http://stackoverflow.com/questions/36504/why-functional-languages" rel="nofollow">http://stackoverflow.com/questions/36504/why-functional-lang...</a><p>[4] - <a href="http://scott.sauyet.com/Javascript/Talk/2014/01/FuncProgTalk/#slide-0" rel="nofollow">http://scott.sauyet.com/Javascript/Talk/2014/01/FuncProgTalk...</a>
> The second relies on two external functions and is one line long.<p>> console.log(sum(range(1, 10)));<p>> Which one is more likely to contain a bug?<p>I'd say the second one. Because the first one is totally transparent. The second one relies on functions I can't see. Especially the "range" function may cause problems because here it generates the full range, including both delimiters, unlike the range function in e.g. python.<p>EDIT: functional programming is extremely useful, but I don't think this example really highlights the most important advantages.
In ES6 there are iterables that one uses `for...of` with. Rauschmayer of 2ality has said that `for...of` should be used instead of forEach and I wonder how that will affect composability in functional programming. I quite like the concept of iteratables and creating data structures that can make use of for of and generators. I just have thought about how that affects functional style programming.
in case anyone missed it, it's by the author of CodeMirror [1], Acorn, Tern, etc. [2]. He also contributes to Rust.<p>[1] <a href="https://github.com/codemirror/codemirror" rel="nofollow">https://github.com/codemirror/codemirror</a><p>[2] <a href="https://github.com/marijnh" rel="nofollow">https://github.com/marijnh</a>
The theory is good, but the specifics of JS syntax, the type system, and the lack of support from the standard library make functional programming much less fun to use than in proper functional languages or even C#.