Skip to content
Code Recycle
Free · open sourceMITUnclaimed listing

p-limit is by sindresorhus — not by us.

We indexed this project so people can find it. We are not selling it, we host no copy of the code, and we are not affiliated with or endorsed by its authors — get it from them.

Indexed Sep 19, 2026 · 2,925 stars at index time. Maintainers: claiming verifies your identity and unlocks a higher assurance tier. Removal requests are honored.

Application · for humans & their agents

p-limit

unclaimed listingactively maintainedFreeMIT

Run multiple promise-returning & async functions with limited concurrency

by Open Source Community · New publisher

Go to the project ↗

Every claim on this page is refundable if it is untrue — refund policy.

Run multiple promise-returning & async functions with limited concurrency

sindresorhus/p-limit is an open-source project by sindresorhus: Run multiple promise-returning & async functions with limited concurrency. Indexed here so it can be found — not resold.

It is free. Get it from the upstream repository: https://github.com/sindresorhus/p-limit

From the project's own README (excerpt, reproduced for discovery under its MIT license):

p-limit

> Run multiple promise-returning & async functions with limited concurrency

Works in Node.js and browsers.

Install

Usage

API

pLimit(concurrency) default export

Returns a limit function.

concurrency

Type: number object\ Minimum: 1

Concurrency limit.

You can pass a number or an options object with a concurrency property.

rejectOnClear

Type: boolean\ Default: false

Reject pending promises with an AbortError when clearQueue() is called. This is recommended if you await the returned promises, for example with Promise.all, so pending tasks do not remain unresolved after clearQueue().

limit(fn, ...args)

Returns the promise returned by calling fn(...args).

fn

Type: Function

Promise-returning/async function.

args

Any arguments to pass through to fn.

Support for passing arguments on to the fn is provided in order to be able to avoid creating unnecessary closures. You probably don't need this optimization unless you're pushing a lot of functions.

Warning: Avoid calling the same limit function inside a function that is already limited by it. This can create a deadlock where inner tasks never run. Use a separate limiter for inner tasks.

limit.map(iterable, mapperFunction)

Process an iterable of inputs with limited concurrency.

The mapper function receives the item value and its index.

Returns a promise equivalent to Promise.all(Array.from(iterable, (item, index) => limit(mapperFunction, item, index))).

If the iterable throws during iteration, the returned promise rejects with that error. Mapper functions that were already scheduled still run, and their results are discarded.

This is a convenience function for processing inputs that arrive in batches. For more complex use cases, see p-map.

limit.activeCount

The number of promises that…

01Capabilities

Does

  • No capabilities recorded

Doesn’t

  • No exclusions declared

02Requirements & stack

Depends on

No declared dependencies

Credentials needed

None declared

Stack

javascript

03Community

No endorsements yet

No verified confirmations yet — be the first.

Confirmations come from verified purchasers, installers, vetted reviewers, or an installation outcome your org reported through the agent tools. They grade quality — security is verified separately, and community votes can never override the security gate.

Open an issue

Sign in to confirm — weight comes from verified usage, not vote count.

Nobody has reported anything yet — a success counts as a report too.

04Trust Passport

Full passport →
–/100

0/0 automated components pass. An automated score is never a security guarantee.

This listing is unclaimed, so publisher identity cannot be verified and it stays below the “verified” tier by design — that is a statement about the listing, not about the project’s quality. Our automated scans still ran; a maintainer who claims it unlocks identity verification.

VersionChannelReleasedNotes
0.0.0stableSep 19, 2026Indexed listing — see the upstream repository for real release history.