DataTable
constSource L208Open-code aq-ui accessible component family for Data Table.
const DataTable = DataTableForwardRef as DataTableComponent<DataTable />
Open-code aq-ui accessible component family for Data Table.
This is a live example. Interact with the available controls and use the keyboard to inspect the component's states and behavior.
pnpm dlx aq-ui@alpha add data-tableImport the parts you need, then jump to an export for its contract.
"use client"
import { DataTable } from "@/components/ui/data-table"
<DataTable />Open-code aq-ui accessible component family for Data Table.
const DataTable = DataTableForwardRef as DataTableComponentType contract for DataTableProps.
interface DataTableProps<TData, TValue> extends Omit< React.ComponentPropsWithoutRef<"div">, "children" >| Name | Type |
|---|---|
columns | ColumnDef<TData, TValue>[] |
data | TData[] |
emptyMessage? | React.ReactNode |
pageSize? | number |
enablePagination? | boolean |
enableRowSelection? | boolean |
className? | string |
toolbar? | (table: ReturnType<typeof useReactTable<TData>>) => React.ReactNode |
getRowId? | (row: TData, index: number) => string |
onRowSelectionChange? | (selection: RowSelectionState) => void |
button, table, utils
@tanstack/react-table@^8.21.3
| Project | Framework | Status |
|---|---|---|
| Documentation | Next.js | Ready |
| Dashboard | Vite | Ready |
| Portal | React Router | Building |
6 row(s)