curryjs
v0.1.0
Published
simple, naive, small library for currying function in javascript
Downloads
3
Maintainers
Readme
Installation
npm install curryjs
Usage
var curryJs = require('curryjs')
var composeJs = require('composejs')
var split = curryJs(function (delim, str) { return str.split(delim)})
var join = curryJs(function (delim, arr) { return arr.join(delim)})
var map = curryJs(function (fn, arr) { return arr.map(fn)})
var toLowerCase = Function.prototype.call.bind(String.prototype.toLowerCase)
var composed = composeJs(join(' '), map(toLowerCase), split(' '))
composed('Hello World') // hello world
License
MIT © [Adhitya Ramadhanus]