p-any
You probably want this instead of Promise.race(). Reason. With Node.js 15, there's now a built-in…
Official Documentation ↗v5.0.0. Check the official docs for the latest API surface.Installation
npm install p-anypnpm add p-anyMethods
No methods match this filter.
Overview
You probably want this instead of Promise.race(). Reason. With Node.js 15, there’s now a built-in [Promiseany](https://developer.mozilla.org/en-US/docs/Web/JavaScript/
API reference status
This page lists only entry points that appear verbatim in the official README examples: head, pAny. Parameter and return types are not given by the official README, so signatures are marked unverified.
Errors
The following points are quoted verbatim from the official documentation. 来源:https://cdn.jsdelivr.net/gh/sindresorhus/p-any@latest/readme.md · 取证方式:HTTP GET 官方 README/文档页(HTML 去标签) · 抓取时间:2026-11-07T13:51:24.880Z. Any error type, throw condition or recovery step not stated there is left unspecified; this page does not infer exception classes or return values.
- If all the input promises reject, it will reject with an AggregateError error. (https://cdn.jsdelivr.net/gh/sindresorhus/p-any@latest/readme.md)
Verification notes
- Official source: https://github.com/sindresorhus/p-any
- Evidence: https://cdn.jsdelivr.net/gh/sindresorhus/p-any@latest/readme.md
- Checked on 2026-11-04 by
scripts/phase11/build-api-profiles.mjs
API reference evidence
Fetched from official sources on 2026-11-08T18:35:00+08:00 via WebFetch https://cdn.jsdelivr.net/gh/sindresorhus/p-any@latest/index.d.ts.
pAny→ signature from https://cdn.jsdelivr.net/gh/sindresorhus/p-any@latest/index.d.ts; official text: “export default function pAny( input: Iterable<Value >, options?: Options ): CancelablePromise ; export {AggregateError} from ‘p-some’;”
FAQ
- What does p-any do?
- You probably want this instead of Promise.race().
- How do I install p-any?
- Run `npm install p-any`.
- Where can I verify the API details?
- Official repository/documentation: https://github.com/sindresorhus/p-any. Checked on 2026-11-04; signatures and return values not stated in the official README are marked unverified.
Report a problem with this API docOpens a pre-filled issue on GitHub.