instant-curry

1.2.0 • Public • Published

Instant Curry

Lightweight Function Currying

import curry from 'instant-curry';

let lazyAdd = curry( (a, b, c, d) => a+b+c+d );


lazyAdd(1, 2, 3, 4); // 10
lazyAdd(1, 2, 3)(4); // 10
lazyAdd(1, 2)(3, 4); // 10
lazyAdd(1)(2)(3)(4); // 10

Dependencies (0)

    Dev Dependencies (4)

    Package Sidebar

    Install

    npm i instant-curry

    Weekly Downloads

    3

    Version

    1.2.0

    License

    MIT

    Last publish

    Collaborators

    • tuxsudo