Skip to content

IReadOnlyObservableCollection.toSorted

github-actions[bot] edited this page Dec 3, 2024 · 3 revisions

Returns a JavaScript Array containing the items of the collection in ascending order.

toSorted(
  compareCallback?: (a: Exclude<TItem, undefined>, b: Exclude<TItem, undefined>) => number
): TItem[]

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

Parameters

Returns: TItem[]

A new Array containing the elements sorted in ascending order.

See also

Clone this wiki locally