Documentation

@kanunilabs/pivotgrid-react


@kanunilabs/pivotgrid-react / PivotGridRef

Interface: PivotGridRef

Imperative API handle exposed via React ref or Angular adapter.

Properties

collapseAll

collapseAll: () => void

Returns

void


expandAll

expandAll: () => void

Returns

void


exportData

exportData: (format, options?) => Promise<void>

Returns a promise so a caller can handle a refusal.

It used to be void. That was harmless while an unavailable format was a console.warn and a resolved promise; the controller now REJECTS for the three Enterprise formats, and a void return meant the caller could not catch it even if they wanted to. Widening void to Promise<void> is source-compatible — existing callers ignore the return either way.

Parameters

format

string

options?

ExportOptions

Returns

Promise<void>


getCell

getCell: (rowPath, colPath) => PivotCell<any> | null

Parameters

rowPath

string[]

colPath

string[]

Returns

PivotCell<any> | null


getEngineResult

getEngineResult: () => PivotEngineResult | null

Returns

PivotEngineResult | null


getRawData

getRawData: () => unknown[]

Returns

unknown[]


getState

getState: () => PivotControllerState

Returns

PivotControllerState


refreshEngine

refreshEngine: () => void

Returns

void


setFields

setFields: (fields) => void

Parameters

fields

PivotField<any, PivotCellTemplate, any>[]

Returns

void