pipe-promise
Run asynchronous pipelines with helper functions for common array operations.
If the first argument isn't a promise, and no function return a promises, then the pipeline runs synchronously.
Helper functions
- map
- filter
- reduce
- foreach
Examples
Require:
const pipe map filter reduce foreach =
Async pipeline using await:
await // 7
Sync pipeline:
// 7
foreach:
foreach()
runs sequentially and returns the input data
// [ 1, 2, 3 ]