SelectionMethods
Selection convenience methods returned from useGrid.
Example
Section titled “Example”// Old (deprecated)const { selectAll, clearSelection } = useGrid();
// New (recommended)import { useGridSelection } from '@toolbox-web/grid-react/features/selection';const { selectAll, clearSelection, getSelectedRows } = useGridSelection();Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
selectAll | () => void | ⚠️ Select all rows in the grid. Requires SelectionPlugin with mode: ‘row’. |
clearSelection | () => void | ⚠️ Clear all selection. Works with any SelectionPlugin mode. |
getSelectedIndices | () => Set<number> | ⚠️ Get selected row indices. Returns Set of selected row indices. |
getSelectedRows | () => TRow[] | ⚠️ Get selected rows data. Returns array of selected row objects. |
AI assistants: For complete API documentation, implementation guides, and code examples for this library, see https://raw.githubusercontent.com/OysteinAmundsen/toolbox/main/llms-full.txt