UNPKG

asyncerator

Version:

Provide supporting types for AsyncIterable/AsyncIterableIterators, promisified stream.pipeline implementation, and Array-like utility operators, sources and sinks.

10 lines (9 loc) 387 B
import type { Asyncerator } from '../asyncerator'; /** * Similar to Promise.all(), but instead returns values as they become available via an Asyncerator. * Note: the output order is different from the input order, the fastest promise to resolve * will be first, the slowest last. * * @param promises */ export default function <T>(promises: Iterable<Promise<T>>): Asyncerator<T>;