• Creates a Promise that is resolved with an array of results when all of the provided Promises resolve or reject.

    Type Parameters

    • T extends [] | readonly unknown[]

    Parameters

    • values: T

      An array of Promises.

    Returns Promise<{
        -readonly [P in string | number | symbol]: PromiseSettledResult<Awaited<T[P<P>]>>
    }>

    A new Promise.

  • Creates a Promise that is resolved with an array of results when all of the provided Promises resolve or reject.

    Type Parameters

    • T

    Parameters

    • values: Iterable<T | PromiseLike<T>, any, any>

      An array of Promises.

    Returns Promise<PromiseSettledResult<Awaited<T>>[]>

    A new Promise.