MCPcopy Create free account
hub / github.com/angular/components / sort

Method sort

src/cdk/collections/selection-model.ts:147–151  ·  view source on GitHub ↗

* Sorts the selected values based on a predicate function.

(predicate?: (a: T, b: T) => number)

Source from the content-addressed store, hash-verified

145 * Sorts the selected values based on a predicate function.
146 */
147 sort(predicate?: (a: T, b: T) => number): void {
148 if (this._multiple && this.selected) {
149 this._selected!.sort(predicate);
150 }
151 }
152
153 /**
154 * Gets whether multiple values can be selected.

Callers

nothing calls this directly

Calls 1

sortMethod · 0.65

Tested by

no test coverage detected