Column
TIP
This page refers to the table's column objects that are generated within the table instance. Refer to this link for the column definitions API.
The Column types are organized by feature. All feature types are ultimately joined in the single Column type definition.
API
CoreColumn
Basic column properties available on all columns regardless of features enabled. Includes column identification (id), hierarchy information (depth, parent), and references to associated rows and column definitions.
(
item: TData,
) => string | string[]
ColumnDef<
TData,
TValue,
TColumnMeta
>
Column[]
number() => Column<
TData,
TValue,
ColumnMeta
>[]
() => Column<
TData,
TValue,
ColumnMeta
>[]
string- A manual
id property from the column def- The accessor key from the column def
- The header string from the column def
Column<
TData,
TValue
>
FiltersColumn
Properties and methods for filtering column data. Provides access to filter functions, filter values, and methods to apply or clear filters. See the Column Filtering guide for implementation details.
() => FilterFn<TData>
() => boolean
column filtered.() => boolean
false
to disable a column from being scanned during global filtering.() => [
number,
number,
]
options.getFacetedMinMaxValues. A default implementation is provided via the
exported getFacetedMinMaxValues function.() => RowModel<TData>
options.facetedRowModel. A
default implementation is provided via the exported getFacetedRowModel
function.() => Map<
any,
number
>
Map of unique values and their
occurrences derived from column.getFacetedRowModel. Useful for displaying
faceted result values. Requires that you pass a valid getFacetedUniqueValues function to options.getFacetedUniqueValues. A default
implementation is provided via the exported getFacetedUniqueValues
function.() => FilterFn<TData>
() => number
state.columnFilters
array. Returns -1 if not found.() => unknown
() => boolean
(
updater: any,
) => void
SortingColumn
Properties and methods for controlling column sort behavior. Includes sort direction state, sort functions, and methods to toggle or clear sorting. See the Sorting guide for implementation details.
() => void
() =>
| 'asc'
| 'desc'
() => any
() => boolean
() => boolean
() =>
| 'asc'
| 'desc'
Useful for tooltips and aria-labels.
() =>
| false
| 'asc'
| 'desc'
() =>
| false
| 'asc'
| 'desc'
() => number
() => any
() => (
event: unknown,
) => void
(
desc?: boolean,
isMulti?: boolean,
) => void
desc is provided, it will force the
sort direction to that value. If isMulti is provided, it will additivity
multi-sort the column (or toggle it if it is already sorted).GroupingColumn
Properties and methods for grouping rows by column values and aggregating grouped data. Provides access to aggregation functions, grouped row state, and methods to toggle grouping. See the Grouping guide for implementation details.
AggregationFn
The AggregationFn interface is used on several of the GroupingColumn properties.
export type AggregationFn<TData extends RowData> = (
columnId: string,
leafRows: Row<TData>[],
childRows: Row<TData>[],
) => any() => AggregationFn<TData>
() => AggregationFn<TData>
() => boolean
() => number
() => boolean
() => () => void
onClick prop of a button.() => void
VisibilityColumn
Properties and methods for controlling column visibility state. Provides methods to show, hide, or toggle column visibility. See the Column Visibility guide for implementation details.
() => boolean
() => boolean
() => (
event: unknown,
) => void
(
value?: boolean,
) => void
ColumnPinningColumn
Properties and methods for pinning columns to the left or right side of the table. Includes pinning state and methods to pin or unpin columns. See the Column Pinning guide for implementation details.
() => boolean
() =>
| false
| 'left'
| 'right'
'left', 'right' or false)() => boolean
() => boolean
() => number
(
position:
| false
| 'left'
| 'right',
) => void
'left' or 'right', or unpins the column to the center
if false is passed.ColumnSizingColumn
Properties and methods for managing column width and resizing behavior. Includes current size, min/max constraints, and methods to set or reset column dimensions. See the Column Sizing guide for implementation details.
() => boolean
true if the column can be resized.() => boolean
true if the column is currently being resized.() => number
(
position?:
| false
| 'left'
| 'right',
) => number
() => void