5.0
API
Types
Cell

Definition

type Cell = {
  rowIndex: number;
  colIndex: number;
  Template: React.ComponentType<any>;
  props?: React.ComponentPropsWithRef<Cell["Template"]>;
  rowSpan?: number;
  colSpan?: number;
  isFocusable?: boolean;
  isSelectable?: boolean;
};

Properties

NameTypeDescription
rowIndexnumberUser-defined row index, must exist in the rows array.
colIndexnumberUser-defined column index, must exist in the columns array.
TemplateReact.ComponentType<any>Cell's template, typically the name of the React component. Should start with an uppercase letter.
propsReact.ComponentPropsWithRef<Cell["Template"]>Props passed to the cell's template. It's an object inherited from the Template prop.
rowSpannumber (optional)Represents how many rows the cell should occupy.
colSpannumber (optional)Represents how many columns the cell should occupy.
isFocusableboolean (optional)Marks a cell as focusable or not.
isSelectableboolean (optional)Marks a cell as selectable or not.