UNPKG

fishbird

Version:

Fishbird is a simple, lightweight, and fast Promise utility library

13 lines (11 loc) 449 B
type PromiseOrValue<T> = T | Promise<T>; type IteratorFn<IN, OUT, COLLECTION = IN> = (item: Awaited<IN>, index: number, collection: COLLECTION) => OUT; interface Options { concurrency?: number; } type ArrayCollection<T> = T[]; interface RecordCollection<T> extends Record<string, T> { } interface MapCollection<T> extends Map<string, T> { } export type { ArrayCollection, IteratorFn, MapCollection, Options, PromiseOrValue, RecordCollection };