npm / p-limit
p-limit
What changed in p-limit 3 to 7, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.
10 breaking3 new APIs and options1 performance1 behavior and defaults5 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initp-limit 711 changes
Breaking changes 2
activeCount increments when tasks actually start running rather than when queued, so it reflects truly active promises.
Node.js 20 is now required to use p-limit.
New APIs and options 3
pLimit() now supports an options object.
Adds the rejectOnClear option to pLimit().
Adds a .map convenience method.
Performance 1
Performance is improved.
Behavior and default changes 1
The
.map()method accepts an iterable, not just an array.
Fixes and other changes 4
Fixes unhandled rejections in limit.map() when the iterable throws.
Fixes queue clearing in limitFunction.
Fixes detached limit.map calls.
pendingCount more accurately represents tasks waiting to run.
p-limit 62 changes
Breaking changes 2
The timing of activeCount changes slightly as part of a performance improvement.
The timing of pendingCount changes slightly as part of a performance improvement.
p-limit 52 changes
Breaking changes 1
Node.js 18 is now required to use this package.
Fixes and other changes 1
Fixed an AsyncResource propagation issue.
p-limit 42 changes
Breaking changes 2
Node.js 12.20 is now required to use the package.
The package is now pure ESM, changing how developers import and use it.
p-limit 33 changes
Breaking changes 3
Limited functions always run asynchronously.
Node.js 10 is now required.
TypeScript users must use a CommonJS import assignment instead of a default import.