@szilanor/stream
    Preparing search index...

    Function containsAsync

    • Returns a collector that returns true if at least one of the entries equals with the given 'value'.

      Type Parameters

      • T

        Type of items in the source.

      Parameters

      • value: T

        Value to search for.

      • equalsFunction: EqualsFunction<T> = ...

        Function to compare items.

      Returns AsyncCollectorFunction<T, boolean>

      Collector that returns true if at least one of the entries equals with the given 'value'.

      const result = containsAsync(2)([1, 2, 3]);
      console.log(result); // true