https://github.com/kozlown/super-curry
Optimized utility to currify any function 🔥
https://github.com/kozlown/super-curry
curry es6 javascript library npm optimized package partial-application utility
Last synced: 3 months ago
JSON representation
Optimized utility to currify any function 🔥
- Host: GitHub
- URL: https://github.com/kozlown/super-curry
- Owner: kozlown
- License: mit
- Created: 2018-04-25T21:47:29.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-05-30T08:51:37.000Z (over 7 years ago)
- Last Synced: 2025-05-07T11:57:08.760Z (5 months ago)
- Topics: curry, es6, javascript, library, npm, optimized, package, partial-application, utility
- Language: JavaScript
- Homepage:
- Size: 10.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# super-curry [](https://travis-ci.com/kozlown/super-curry)
Optimized utility to currify any function.## Examples
See it in action [here](https://repl.it/@kozlown/super-curry)
```js
import curry from 'super-curry'const linear = curry(
(a, x, b) => a * x + b
)// it can be called normally
console.info(linear(2, 6, 3))
// 2 * 6 + 3 = 15// with simple partial application
const linearBy4 = linear(4)
console.info(linearBy4(5, 2))
// 4 * 5 + 2 = 22// or with placeholder(s)
const linearBy4Plus2 = linear(4, curry, 2)
// linearBy4(curry, 2) works too
console.info(linearBy4Plus2(6))
// 4 * 6 + 2 = 26
```