promise-map-series

WebJar for promise-map-series

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

promise-map-series
Последняя версия

Последняя версия

0.2.3
Дата

Дата

Тип

Тип

jar
Описание

Описание

promise-map-series
WebJar for promise-map-series
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/joliss/promise-map-series

Скачать promise-map-series

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/promise-map-series/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>promise-map-series</artifactId>
    <version>0.2.3</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/promise-map-series/
implementation 'org.webjars.npm:promise-map-series:0.2.3'
// https://jarcasting.com/artifacts/org.webjars.npm/promise-map-series/
implementation ("org.webjars.npm:promise-map-series:0.2.3")
'org.webjars.npm:promise-map-series:jar:0.2.3'
<dependency org="org.webjars.npm" name="promise-map-series" rev="0.2.3">
  <artifact name="promise-map-series" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='promise-map-series', version='0.2.3')
)
libraryDependencies += "org.webjars.npm" % "promise-map-series" % "0.2.3"
[org.webjars.npm/promise-map-series "0.2.3"]

Зависимости

compile (1)

Идентификатор библиотеки Тип Версия
org.webjars.npm : rsvp jar [3.0.14,4)

Модули Проекта

Данный проект не имеет модулей.

promise-map-series

Build Status

Call an iterator function for each element of an array in series, ensuring that no iterator is called before the promise returned by the previous iterator is fulfilled, in effect preventing parallel execution. Like async.mapSeries, but for promises.

Installation

npm install --save promise-map-series

Usage

var mapSeries = require('promise-map-series')

mapSeries(array, iterator[, thisArg]).then(function (newArray) {
  ...
})
  • array: An array of values (should not be promises).

  • iterator: Function that returns a promise or a value for the new array. The iterator will be called once for each element. If iterator returns a promise, then iterator will only be called for the next element once that promise is fulfilled. If the promise is rejected or iterator throws an error, iteration will stop immediately and mapSeries returns a rejected promise. The iterator function receives three arguments:

    • item: The current item in the array.

    • index: The current index in the array.

    • array: The original array argument.

  • thisArg (optional): Value to use as this when executing iterator.

Версии библиотеки

Версия
0.2.3
0.2.1