Currying is a functional programming technique which transforms a function that takes multiple arguments into a sequence of nesting functions that each take only a single argument. Native Javascript does not include the curry function, but many libraries do. With lodash, converting a function to a curried version is as simple as passing your function into _curry.

3m read timeFrom levelup.gitconnected.com
Post cover image
Table of contents
So what exactly is this “currying”?Let’s explore this concept with a simple example.Can all functions be “curried”?Cool! So…why is this important?

Sort: