Docs
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
Table API Reference
Column API Reference
Row API Reference
Cell API Reference
Header API Reference
Features API Reference
Static Functions API Reference
Legacy API Reference
Static Functions API Reference

column_toggleSorting

Function: column_toggleSorting()

ts
function column_toggleSorting<TFeatures, TData, TValue>(
   column, 
   desc?, 
   multi?): void;
function column_toggleSorting<TFeatures, TData, TValue>(
   column, 
   desc?, 
   multi?): void;

Defined in: features/row-sorting/rowSortingFeature.utils.ts:187

Applies the next sorting state for this column.

The toggle can add, replace, flip, or remove this column's sort entry. Multi sorting respects enableMultiSort, maxMultiSortColCount, and the multi argument.

Type Parameters

TFeatures

TFeatures extends TableFeatures

TData

TData extends RowData

TValue

TValue extends unknown = unknown

Parameters

column

Column_Internal<TFeatures, TData, TValue>

desc?

boolean

multi?

boolean

Returns

void

Example

ts
column_toggleSorting(column, undefined, true)
column_toggleSorting(column, undefined, true)