Displaying 1 to 11 from 11 results

p-times - Run promise-returning & async functions a specific number of times concurrently


Returns a Promise that is fulfilled when all promises returned from mapper are fulfilled, or rejects if any of the promises reject. The fulfilled value is an Array of the fulfilled values returned from mapper in order.Number of times to call mapper.




p-filter - Filter promises concurrently


Useful when you need to run promise-returning & async functions multiple times with different inputs concurrently and get a filtered down result.Returns a Promise that is fulfilled when all promises in input and ones returned from filterer are fulfilled, or rejects if any of the promises reject. The fulfilled value is an Array of the fulfilled values returned from filterer in input order.

p-map - Map over promises concurrently


Useful when you need to run promise-returning & async functions multiple times with different inputs concurrently.Returns a Promise that is fulfilled when all promises in input and ones returned from mapper are fulfilled, or rejects if any of the promises reject. The fulfilled value is an Array of the fulfilled values returned from mapper in input order.

p-props - Like `Promise.all()` but for `Map` and `Object`


Useful when you need to run multiple promises concurrently and keep track of the fulfilled values by name.Returns a Promise that is fulfilled when all promises in input are fulfilled, or rejects if any of the promises reject. The fulfilled value is the same as input, but with a fulfilled version of each entry value.


p-queue - Promise queue with concurrency control


Useful for rate-limiting async operations. For example, when interacting with a REST API or when doing CPU/memory intensive tasks.Here we run only one promise at the time. For example, set concurrency to 4 to run four promises at the time.

p-retry - Retry a promise-returning or async function


It does exponential backoff and supports custom retry strategies for failed operations.Returns a Promise that is fulfilled when calling input returns a fulfilled promise. If calling input returns a rejected promise, input is called again until the max retries are reached, it then rejects with the last rejection reason.

p-one - Test whether some promise passes a testing function


Like Array.some for promises. Returns a Promise that is fulfilled when any promise in input and ones returned from testFn are fulfilled, or rejects if any of the promises reject. The fulfilled value is a boolean that is true if any promise passed the test and false otherwise.