twice-call-wrapper
v1.2.5
Published
A small wrapper that calls a function twice: fn(fn(args))
Maintainers
Readme
twice-call-wrapper
Returns a wrapper that calls a function twice, passing in the result of the first time into the second time.
Installation
$ npm i twice-call-wrapperUsage
var calledtwice = require('twice-call-wrapper');
var double = v => v * 2; // a simple function that doubles a number
var doubleTwice = calledtwice(double);
console.log(doubleTwice(5)) // quadruples a number because it doubles it and then doubles it again, like double(double(5))License
MIT Licensed
Contributing
Contribute on the github repository! PRs and Issues are welcome.
