Documentation

@kanunilabs/datagrid-react


@kanunilabs/datagrid-react / UseDataGridLifecycle

Interface: UseDataGridLifecycle

Properties

attachedTo?

optional attachedTo?: RefObject<Element | null>

The grid's root element (B.108). With it, the controller outlives <Activity mode="hidden">: while the element is still in the document the grid is only hidden and keeps its rows, state and unsaved edits; once React has removed it (an unmount) the controller is disposed as before. Without it every effect cleanup disposes, and a grid hidden by <Activity> is rebuilt — reset — when shown.