Skip to Content
Mastering JavaScript Functional Programming - Second Edition
book

Mastering JavaScript Functional Programming - Second Edition

by Federico Kereki
January 2020
Intermediate to advanced
470 pages
11h 13m
English
Packt Publishing
Content preview from Mastering JavaScript Functional Programming - Second Edition

Other patterns

Let's end this section by glancing at some other patterns, where the equivalence may or may not be so good:

  • Currying and Partial Application (which we saw in Chapter 7, Transforming Functions – Currying and Partial Application): This can be seen as approximately equivalent to a Factory for functions. Given a general function, you can produce specialized cases by fixing one or more arguments, and this is, in essence, what a Factory does, of course, speaking about functions and not objects.
  • Declarative functions (such as map() or reduce()): They can be considered an application of the Iterator pattern. The traversal of the container's elements is decoupled from the container itself. You might also provide different map() methods ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering JavaScript Functional Programming

Mastering JavaScript Functional Programming

Federico Kereki

Publisher Resources

ISBN: 9781839213069Supplemental Content