The state of a table changed (EventListenerIf.onStateChanged): a column was resized, moved, hidden, the table was sorted, scrolled, a node expanded, a row checked or selected … Reported once after the changes settled (TableOptionsIf.stateChangedDebounceDelay, default 300 ms) and only if a part really changed; not while the table is built.

Example

const listener = new EventAdapter();
listener.onStateChanged = (evt: GeStateChangeEvent) => {
if (!evt.changedParts.includes("scroll")) { // e.g. ignore pure scrolling
void fetch("/api/prefs/orders", { method: "PUT", body: JSON.stringify(evt.state) });
}
};

Since

1.1.92

Hierarchy

  • GeStateChangeEvent

Constructors

Properties

Constructors

Properties

changedParts: TableStatePart[]

The parts that changed since the last event.

The whole state of the table now (all parts).