# getSortedRowModel

# ~~Function: getSortedRowModel()~~

```ts
function getSortedRowModel<TData>(): RowModelFactory<TData>;
```

Defined in: [useLegacyTable.ts:63](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L63)

## Type Parameters

### TData

`TData` *extends* `RowData`

## Returns

`RowModelFactory`\<`TData`\>

## Deprecated

Use `createSortedRowModel(sortFns)` with the new `useTable` hook instead.

This is a stub function for v8 API compatibility with `useLegacyTable`.
It acts as a marker to enable the sorted row model.
