API REFERENCE
getContextMenuItems
Calculates context-menu items for a displayed row and field.
What does this API do?
Calculates context-menu items for a displayed row and field.
API for Pro features: Built-in context menu
Exact input and result types
getContextMenuItems(target: { rowIndex: number; field?: string }): Promise<ContextMenuItem[]>| Arguments | Required | Type |
|---|---|---|
| target | Required | { rowIndex: number; field?: string } |
The return type is Promise<ContextMenuItem[]>.
Usage flow
After registering and initializing the Grid element, call grid.getContextMenuItems(…). Read the return value with await. For methods returning a boolean or report, inspect the result before continuing.
Read related types
Feature explanations and examples
- Cell context menus
A cell's context menu offers actions such as Copy, Copy row, and Export for the current location. Also provide toolbar or keyboard access to frequently used features.