pipelinejs
A simple Pipeline implementation for Javascript
Install
npm i --save pipelinejs
Usage
{return _+1}{return _*2}{return _length}{return _*_}// if you put data into constructor, it will pipe directly// 8. equals to double(inc(3))// and you can put data laterlet ppl1 =// 6. equals to double(length([1,2,3]))ppl1length // 2. number of functions in pipelineppl10 // [Function]// you can use `push` `pop` `shift` `unshift` and any other array methodppl1 // push function `square` into pipeline// 36. equals to square(double(length([1,2,3])))// you can combine two pipelinelet ppl2 =let ppl3 =// 49. equals to square(inc(double(length([1,2,3]))))