apr-for-each
Advanced tools
Comparing version 1.0.4 to 1.0.5
@@ -29,4 +29,4 @@ const each = require('apr-engine-each'); | ||
*/ | ||
module.exports = (input, fn, opts) => { | ||
return each({ | ||
module.exports = (input, fn, opts) => | ||
each({ | ||
input, | ||
@@ -36,5 +36,4 @@ fn, | ||
}); | ||
}; | ||
module.exports.series = require('./series'); | ||
module.exports.limit = require('./limit'); |
14
limit.js
@@ -13,10 +13,12 @@ const defaults = require('lodash.defaults'); | ||
*/ | ||
module.exports = (input, limit, fn, opts) => { | ||
return each({ | ||
module.exports = (input, limit, fn, opts) => | ||
each({ | ||
input, | ||
fn, | ||
opts: defaults({ | ||
limit | ||
}, opts) | ||
opts: defaults( | ||
{ | ||
limit | ||
}, | ||
opts | ||
) | ||
}); | ||
}; |
{ | ||
"name": "apr-for-each", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "Applies the function iteratee to each item in coll, in parallel.", | ||
@@ -13,5 +13,13 @@ "keywords": [ | ||
"control-flow", | ||
"awaitful" | ||
"awaitful", | ||
"promises", | ||
"async-await", | ||
"es2015", | ||
"es2016", | ||
"es2017", | ||
"es6", | ||
"es7", | ||
"es8" | ||
], | ||
"homepage": "https://ramitos.github.io/apr#for-each", | ||
"homepage": "https://apr.js.org#for-each", | ||
"bugs": "https://github.com/ramitos/apr/issues", | ||
@@ -26,5 +34,5 @@ "license": "MIT", | ||
"dependencies": { | ||
"apr-engine-each": "^1.0.1", | ||
"apr-engine-each": "^1.0.2", | ||
"lodash.defaults": "^4.2.0" | ||
} | ||
} |
@@ -13,2 +13,4 @@ <!-- Generated by documentation.js. Update this documentation by updating the source code. --> | ||
- `input` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) | Iterable)** | ||
- `fn` | ||
- `opts` | ||
- `iteratee` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** | ||
@@ -40,2 +42,4 @@ | ||
- `input` **([Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array) \| [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object) | Iterable)** | ||
- `fn` | ||
- `opts` | ||
- `iteratee` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** | ||
@@ -51,4 +55,6 @@ | ||
- `limit` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** | ||
- `fn` | ||
- `opts` | ||
- `iteratee` **[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function)** | ||
Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise)** |
@@ -11,4 +11,2 @@ const limit = require('./limit'); | ||
*/ | ||
module.exports = (input, fn, opts) => { | ||
return limit(input, 1, fn, opts); | ||
}; | ||
module.exports = (input, fn, opts) => limit(input, 1, fn, opts); |
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
4792
0
58
67
Updatedapr-engine-each@^1.0.2