row_getParentRows

Function: row_getParentRows()

ts
function row_getParentRows<TFeatures, TData>(row): Row<TFeatures, TData>[];

Defined in: core/rows/coreRowsFeature.utils.ts:140

Collects this row's ancestor chain from root to direct parent.

The current row is not included. Rows without a parent return an empty array.

Type Parameters

TFeatures

TFeatures extends TableFeatures

TData

TData extends RowData

Parameters

row

Row<TFeatures, TData>

Returns

Row<TFeatures, TData>[]

Example

ts
const ancestors = row_getParentRows(row)