Your first time on this page? Allow me to give some explanations.
Awesome Functional Programming
A curated list of awesome functional programming stuff in js
Here you can see meta information about this topic like the time we last updated this page, the original creator of the awesome list and a link to the original GitHub repository.
Thank you stoeffel & contributors
View Topic on GitHub:
stoeffel/awesome-fp-js
Search for resources by name or description.
Simply type in what you are looking for and the results will be filtered on the fly.
Further filter the resources on this page by type (repository/other resource), number of stars on GitHub and time of last commit in months.
Libraries
Practical functional Javascript
Ramda Adjunct is the most popular and most comprehensive set of functional utilities for use with Ramda, providing a variety of useful, well tested functions with excellent documentation.
🤘Utility library for functional JavaScript. With ❤️ to Ramda.
Faster and smaller alternative to Ramda
Extended version of Rambda
A modern JavaScript utility library delivering modularity, performance, & extras.
A modern JS utility library
a functional library for coffeescript (and javascript)
tiny (2.7kb) functional programming library using native es5/6 operations
A practical functional programming library for promises
Hardcore Functional Programming for JavaScript
Functional tools that couldn’t be simpler.
A simple function to curry a function with an arbitrary number of arguments.
Currying made simple.
Function composition
A library which aids in making any JavaScript library more functional.
A JavaScript library for building React applications in more functional way. Alternative to JSX.
[DEFUNCT] trifling functional views
An experiment in adding functional pattern matching to JavaScript
Functional programming date manipulation library
Immutable date and time library for javascript
Make native methods available as partially applied functions.
[Unmaintained: please use jsverify instead] A property-based testing library for clearly specifying code invariants and behaviour.
FP library for JavaScript. Supports named-argument style methods.
Javascript Generalized Parser Combinators
Abstraction for managing asynchronous code in JS
Ultra-high performance reactive programming
☯ The simplest signal library possible
Functional Programming Library for JavaScript, TypeScript and Flow ✨⚡️
pico sized functional library
An extremely small, intuitive and fast functional utility library for JavaScript
Functional Programming for EcmaScript(Javascript)
TypeScript Grid Computing Framework supporting RFC (Remote Function Call)
Features from the rust language in javascript: Provides Traits/Type classes & an advanced library for working with sequences/iterators in js
The iterable toolbox
F(unctional) util(ities). Resistance is futile.
[a]synchronous functional programming
Powerful pipes for TypeScript, that chain Promise and ADT for you 🚌 -> ⛰️ -> 🚠 -> 🏂 -> 🚀
Curry All Code
A standard library for functional programming in JavaScript. Typescript support expected mid-2020. -TS.
A lightweight functional JavaScript library that facilitates currying and point-free / tacit programming.
A functionally oriented utility library somewhat based off of Haskell's Prelude module. -TS.
Sophisticated and functionally-minded async with advanced features: coroutines, promises, ES2015 iterables, fantasy-land. -TS.
A function library roughly subsetting Ramda, but written in Typescript and thus more type-friendly. +TS.
Data Structures
Utilities for treating frozen JavaScript objects as persistent immutable collections
Immutable persistent data collections for Javascript which increase efficiency and simplicity.
Create the next immutable state by mutating the current one
ClojureScript's persistent data structures and supporting API from the comfort of vanilla JavaScript
JavaScript & TypeScript persistent and optionally immutable data tree with cursors.
High performance implementation of Immutable Sequence in JavaScript, based on Finger Tree.
Like Underscore, but lazier
Functional Reactive State for JavaScript and TypeScript
😴 Functional programming with lazy immutable iterables
High-performance immutable data structures for modern JavaScript and TypeScript applications. Functional interfaces, deep/composite operations API, mixed mutability API, TypeScript definitions, ES2015 module exports.
🐆 An immutable list with unmatched performance and a comprehensive functional API.
Functional programming, immutable collections and FP constructs for typescript and javascript
TypeScript-STL (Standard Template Library, migrated from C++)
Algebraic Data Types
Specification for interoperability of common algebraic structures in JavaScript
Specification for common algebraic structures in JavaScript based on Fantasy Land
fantasyland extensions for immutablejs
Library for creating tagged constructors.
Refuge from unsafe JavaScript
A small JavaScript library for defining and using union types.
Free monad Collection
Fantasy Land compliant (monadic) alternative to Promises
Common combinators.
port of the haskell package Data.Aviary.Birds. Every thing for your combinatory needs.
A collection of well known Algebraic Data Types for your utter enjoyment.
A utility library to write code in functional programming style in Javascript
Functional programming library for TypeScript - https://gigobyte.github.io/purify/
MojiScript is an async-first, opinionated, and functional library
🥃 Functional Algebraic Data Types
🔧 Tifi solves a problem of the existence of both undefined
and null
. Inspired by the OCaml/Reason utilities for various data types.
A library that assists functional programming by providing a rich set of Monads and other useful functions. +CT, +TS.
Lenses
Composable kmett style lenses
Profunctor implementation of Lenses, Prisms, Traversals, Isos, etc.
Lens library built on ramda
Composable, immutable getters and setters.
A Lens Library for Javascript
Partial lenses is a comprehensive, high-performance optics library for JavaScript
A lodash-inspired lens-like library for Javascript
Functional Languages that Compile to JavaScript
Clojure to JS compiler
Haskell to JavaScript compiler, based on GHC
Converts Elixir to JavaScript
A multi-paradigm programming language with gradual and duck typing that targets PHP and JS
יון no BS JS (under heavy dev)
Lisp that compiles to JavaScript in the Ramda way
Racket to JavaScript Compiler
A type-safe functional programming language for declaratively creating web browser-based graphical user interfaces. Implemented in Haskell.
A small strongly typed programming language that compiles to JavaScript.
A general purpose pure functional programming language with dependent types.
Compiles OCaml bytecode to JavaScript, making it possible to run OCaml programs in the browser.
Reason is a new interface to OCaml, a highly expressive dialect of the ML language featuring type inference and static type checking.
Bucklescript) ReScript is a type-safe language that compiles to the highest quality of clean, readable and performant JavaScript code.
LiveScript has a straightforward mapping to JavaScript and allows you to write expressive code devoid of repetitive boilerplate.
Koka is a function-oriented programming language that seperates pure values from side-effecting computations with a familiar JavaScript like syntax.
A typed superset of JavaScript that compiles to plain JavaScript.
Programming Tools
ESLint rules for functional programming
Monadic Assertions library
Runtime type checking for JS with Hindley Milner signatures
ftor enables ML-like type-directed, functional programming with Javascript including reasonable debugging.
Books
Mostly adequate guide to FP (in javascript)
Pragmatic, balanced FP in JavaScript. @FLJSBook on twitter.
A fool's scriptum on functional programming
the “Six” edition. Starts with as little as possible about functions – but no less! – and builds up towards powerful combinators and decorators. A foundational book. By Reginald Braithwaite (2016)
teaches JavaScript developers functional techniques that will improve extensibility, modularity, reusability, testability, and performance. Through concrete examples and jargon-free explanations, this book teaches you how to apply functional programming to real-life development tasks. By Luis Atencio (2016)
A modern introduction to programming using JavaScript. By Marijn Haverbeke (2014)
teaches how to create code that’s beautiful, safe, and simple to understand and test by using JavaScript’s functional programming support. By Michael Fogus (2013)
teaches functional programming from first principles. It uses JavaScript for all code examples and it uses real-world scenarios. By Eric Normand (2019)
Articles
Jargon from the functional programming world in simple terms!
Avoid The One-off Problem, Infinite Loops, Statefulness and Hidden intent.
An introduction to Functional Programming Concepts in JavaScript. Uses the Ramda library to teach the concepts of composition, pointfree style, and functors through the simplest of examples.
Another introduction to Functional Programming in JavaScript with a focus on three key themes: computation as the application of functions, statelessness, avoiding side effects.
A four-part series introduction functional programming in JavaScript that gets you up to speed what all the hype about functional programming is all about.
Explaining functors concept using JavaScript.
A short overview of how to write reusable and declarative code using currying.
A beginner-friendly introduction to Algebraic Data Types.
Learn to reason about your JavaScript code with type thinking. Algebraic Data Types are introduced as a conceptual basis to reason about program entities.
Use four new features of ES6 – iterables, generators, fat arrows, and for-of – in conjunction with higher-order functions, function composition, and lazy evaluation, to write cleaner and more modular JavaScript.
To those not used to functional programming, Ramda seems to serve no purpose whatsoever. However, it does offer a different style of coding, a style that’s taken for granted in purely functional programming languages: Ramda makes it simple for you to build complex logic through functional composition.
An introduction to the Monad design pattern in JavaScript.
A walk through some practical use cases for specific monadic structures in JavaScript: use the Maybe
monad to handle simple failure cases and model more complex scenarios with the Either
monad or the Validation
applicative functor.
Many articles on various aspects of functional programming in JavaScript by Gleb Bahmutov.
A series of blog posts that reimplements various data structures in JavaScript to better understand their benefits and downsides.
Easy to understand, with some examples, introduction to Functional Programming in Javascript and Elm.
A complete introduction to functional programming patterns by Chet Corcos with a lot of javascript examples.
Learn about functional data structures and their uses in this overview of Facebook's popular library for JavaScript: Immutable.js.
A simple introduction by @ericelliott to functional principles and vocabulary.
A series of articles on learning functional programming and compositional software techniques in JavaScript ES6+ from the ground up by @ericelliott.
Short and easy to understand article about implementing anonymous recursion in JavaScript.
Step by step explanation of how to compose functions in javascript.
Practical code examples to learn functional programming concepts like pure function, immutability, first-class entities, and higher order functions
Introduction to 2 easy monads in Javascript, Maybe & Either.
Showcasing the similarities between F# and JavaScript
A step by step guide to convert imperative JavaScript to more declarative, functional JavaScript.
Videos
A series that builds a “practical” web application with React and functional programming in JavaScript.
Underscore.js claims to be a functional programming library, but is it really?
Learn about practical use cases for functors, applicatives, and monads.
Christian Johansen will show you how you can significantly up your game by leaving loops behind and embracing functions as the primary unit of abstraction.
A series by Mattias Petter Johansson, from the youtube channel FunFunFunction, that is specifically about popularization of functional programming in JavaScript.
A simple and understandable introduction of functional proramming in javascript.
A complete introduction to functional programming in javascript made it easy by ES6.
Seth House explains how ADTs (Algebraic Data Types) can be useful to JavaScript developers.
Examples and Exercises
Learning the functional paradigm with js
A functional javascript workshop. No libraries required (i.e. no underscore), just ES5.
A functional frontend framework.
A puzzle game inspired by functional programming
YouTube search app with ReactJS, Redux, and FP concepts
Example Project & Guide for mastering Promises in Node/JavaScript. Feat. proposed 'Functional River' pattern
Learn to apply techniques from the forefront of computer science research to solve practical problems in Javascript. Discover functional programming and see it demonstrated step-by-step with how to build an example web app using abstract interfaces like Monads, Functors, Monoids and Applicatives. (commercial)
Dozens of exercises with solutions and explanations.
A series of interactive exercises introducing five basic ingredients of functional (reactive) programming: the map
, filter
, concatAll
, reduce
, and zip
functions.
Related Lists
A curated list of awesome functional reactive programming stuff in js
A curated list of functional programming resources such as blog posts, communities, discussion topics, wikis and more.
Yet another resource for collecting articles, videos etc. regarding functional programming
A Learning Path for Functional Programming
Talk
Community with a friendly channel for JavaScript as well as many other channels about functional programming in general.