Function takeWhile

  • Returns a generator that takes elements from the iterable as long as the predicate is true.

    Returns

    Elements

    Type Parameters

    • T

    Parameters

    • iterable: Iterable<T>

      The iterable to inspect.

    • predicate: Predicate<T, any>

      A function invoked per element to check if it should be taken.

    Returns Generator<T, void, unknown>

Generated using TypeDoc