distinctUntilChanged

function stable

distinctUntilChanged<T, K>(comparator?: (previous: K, current: K) => boolean, keySelector: (value: T) => K = identity as (value: T) => K): MonoTypeOperatorFunction<T>

Parameters

comparator

Optional. Default is undefined.

Type: (previous: K, current: K) => boolean.

keySelector

Optional. Default is identity as (value: T) => K.

Type: (value: T) => K.

Returns

MonoTypeOperatorFunction<T>

© 2015–2021 Google, Inc., Netflix, Inc., Microsoft Corp. and contributors.
Code licensed under an Apache-2.0 License. Documentation licensed under CC BY 4.0.
https://rxjs.dev/api/operators/distinctUntilChanged