Editor model · function
rowIndexOf
Which row a node is, or -1 for a node that is not one.
function rowIndexOf(node: UiNode | null, prefix: string): numberimport { rowIndexOf } from '@driftengine/editor';Parameters
| Parameter | Type | Description |
|---|---|---|
node | UiNode | null | |
prefix | string |
In depth
Takes the node routeUiPointer returned, so a caller writes
const at = rowIndexOf(routeUiPointer(...), TREE_ROW_PREFIX) and has the row it clicked.