Props for ResultsTable.
const props: ResultsTableProps = { getRowCanExpand: (row) => (row.original.variants?.length ?? 0) > 0, columnFilterFns: [filters, setFilters],}; Copy
const props: ResultsTableProps = { getRowCanExpand: (row) => (row.original.variants?.length ?? 0) > 0, columnFilterFns: [filters, setFilters],};
interface ResultsTableProps { /** Predicate deciding whether a row can expand to show variant sub-rows. */ getRowCanExpand: (row: Row<Product>) => boolean; /** Controlled column-filter state tuple `[state, setState]`. */ columnFilterFns: [ColumnFiltersState, Dispatch<SetStateAction<ColumnFiltersState>>];} Copy
interface ResultsTableProps { /** Predicate deciding whether a row can expand to show variant sub-rows. */ getRowCanExpand: (row: Row<Product>) => boolean; /** Controlled column-filter state tuple `[state, setState]`. */ columnFilterFns: [ColumnFiltersState, Dispatch<SetStateAction<ColumnFiltersState>>];}
Predicate deciding whether a row can expand to show variant sub-rows.
Controlled column-filter state tuple [state, setState].
[state, setState]
Props for ResultsTable.
Example
Source