Skip to content

IReadOnlyObservableCollection.some

github-actions[bot] edited this page Nov 17, 2024 · 2 revisions

Checks whether some elements in the collection satisfy a given condition.

some<TContext>(
  predicate: (this: TContext, item: TItem, index: number, collection: this) => boolean,
  thisArg?: TContext
): boolean

Source reference: src/collections/observableCollections/IReadOnlyObservableCollection.ts:231.

Generic Parameters

  • TContext - The context type in which the callback is executed.

Parameters

  • predicate: (this:TContext, item:TItem, index:number, collection:this) => boolean
    The callback performing the check for each item.

  • thisArg: TContext
    A value to use as context when checking items.

Returns: boolean

Returns true if the provided predicate is true for at least one item; otherwise false.

See also

Clone this wiki locally