API REFERENCE

getSortModel

Reads current sort columns, directions, and priorities.

What does this API do?

Reads current sort columns, directions, and priorities.

Exact input and result types

typescript
getSortModel(): Promise<SortModelEntry[]>
ArgumentsRequiredType

The return type is Promise<SortModelEntry[]>.

Usage flow

After registering and initializing the Grid element, call grid.getSortModel(…). Read the return value with await. For methods returning a boolean or report, inspect the result before continuing.

Read related types

Feature explanations and examples