promise.reduce
"Returns a promise containing the reduced result from the provided function"
Install
$ npm install promise.reduce --save
Usage
var map = var Promise
API
reduce(input..., reducerFn, initialValue)
-> promise
Returns a promise containing the reduced result of the promisified mappingFn on its elements. Rejection occurs if any supplied promises reject.
Iterable<Promise|any>
input A sequence of promises or instanceof Iterable
Function
mapperFn A mapping function that returns a promise
Function
initialValue The initial value used in the reduction invocation