Function filter

  • Only keep elements where the filter function returns true.

    The filter function can be asynchronous (in which case the resulting iterator will be asynchronous regardless of the input iterator)!

    Type Parameters

    • TIn

    Parameters

    • filterFn: ((v: TIn) => boolean | Promise<boolean>)
        • (v: TIn): boolean | Promise<boolean>
        • Parameters

          • v: TIn

          Returns boolean | Promise<boolean>

    Returns TTransIteratorSyncOrAsync<TIn, TIn>

Generated using TypeDoc