Type alias GeneratorOutput<Iterable>

GeneratorOutput<Iterable>: Iterable extends IsomorphicIterable<infer Item>
    ? Iterable extends ReadOnlyAsyncIterable<Item>
        ? ReadOnlyAsyncIterableIterator<Item>
        : ReadOnlyIterableIterator<Item>
    : never

IsomorphicIterable generator function optional return value.

Remarks

Generator functions in this library can return either an ReadOnlyAsyncIterableIterator or an ReadOnlyIterableIterator depending on the input. This type simplifies the output of said functions.

See

Type Parameters

  • Iterable

    IsomorphicIterable to get the output from.