Skip to content

GridEditorContext

Since v0.0.1

Context object passed to cell editor components.

PropertyTypeDescription
valueTValueThe cell value for this column
rowTRowThe full row data object
columnColumnConfig<TRow>The column configuration
fieldstringField key (may be a nested dotted path, e.g. a.b.c)
rowIdstringStable row identifier (from getRowId). Empty string if no getRowId is configured.
commit(newValue: TValue) => voidCommit the new value and close editor
cancel() => voidCancel editing without saving
updateRow(changes: Partial<TRow>) => voidUpdate other fields in this row while the editor is open. Changes trigger cell-change events with source 'cascade'.
onValueChange?(callback: (newValue: TValue) => void) => voidRegister a callback to receive value updates when the cell is modified externally (e.g., via updateRow() from another cell’s commit).

Register a callback to receive value updates when the cell is modified externally (e.g., via updateRow() from another cell’s commit).

React editors receive the full context at render time; use this to update local state when another cell cascades a change.