applyEachSeries.js 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. 'use strict';
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. var _applyEach = require('./internal/applyEach.js');
  6. var _applyEach2 = _interopRequireDefault(_applyEach);
  7. var _mapSeries = require('./mapSeries.js');
  8. var _mapSeries2 = _interopRequireDefault(_mapSeries);
  9. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  10. /**
  11. * The same as [`applyEach`]{@link module:ControlFlow.applyEach} but runs only a single async operation at a time.
  12. *
  13. * @name applyEachSeries
  14. * @static
  15. * @memberOf module:ControlFlow
  16. * @method
  17. * @see [async.applyEach]{@link module:ControlFlow.applyEach}
  18. * @category Control Flow
  19. * @param {Array|Iterable|AsyncIterable|Object} fns - A collection of {@link AsyncFunction}s to all
  20. * call with the same arguments
  21. * @param {...*} [args] - any number of separate arguments to pass to the
  22. * function.
  23. * @param {Function} [callback] - the final argument should be the callback,
  24. * called when all functions have completed processing.
  25. * @returns {AsyncFunction} - A function, that when called, is the result of
  26. * appling the `args` to the list of functions. It takes no args, other than
  27. * a callback.
  28. */
  29. exports.default = (0, _applyEach2.default)(_mapSeries2.default);
  30. module.exports = exports['default'];