UseGridReturn
Since v0.1.0
Return type for useGrid composable.
Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
element | Ref<DataGridElement<TRow> | unknown> | The grid element reference |
gridElement | Ref<DataGridElement<TRow> | unknown> | ⚠️ The grid element reference. |
isReady | Ref<boolean> | Whether the grid is ready |
config | Ref<GridConfig<TRow, ColumnFieldKey<TRow>> | unknown> | Current grid configuration (reactive) |
getConfig | () => Promise<GridConfig<TRow, ColumnFieldKey<TRow>> | unknown> | Get the effective configuration |
ready | () => Promise<void> | Wait for the grid to finish its first render |
forceLayout | () => Promise<void> | Force a layout recalculation |
getPlugin | (pluginClass: (args: unknown[]) => T) => T | undefined | Get a plugin by its class |
getPluginByName | (name: K) => unknown | undefined | Get a plugin by its registered name (preferred). Uses the type-safe PluginNameMap for auto-completion and return type narrowing. |
toggleGroup | (key: string) => Promise<void> | Toggle a group row |
registerStyles | (id: string, css: string) => void | Register custom styles via document.adoptedStyleSheets |
unregisterStyles | (id: string) => void | Unregister previously registered custom styles |
getVisibleColumns | () => ColumnConfig<TRow, ColumnFieldKey<TRow>>[] | Get currently visible columns (excluding hidden columns) |