Skip to main content
Module

x/rimbu/stream/mod.ts>Reducer.equals

Rimbu is a TypeScript library focused on immutable, performant, and type-safe collections and other tools.
Latest
function Reducer.equals
import { Reducer } from "https://deno.land/x/rimbu@1.2.1/stream/mod.ts";
const { equals } = Reducer;

Returns a Reducer that ouputs true when the received elements match the given other stream source according to the eq instance, false otherwise.

Parameters

other: StreamSource<T>
  • a stream source containg elements to match against
optional
options: { eq?: Eq<T>; negate?: boolean; } = [UNSUPPORTED]
  • (optional) an object containing the following properties:
  • eq: (default: Eq.objectIs) the Eq instance to use to compare elements
  • negate: (default: false) when true will invert the given predicate

Returns

Reducer<T, boolean>