Staged row model pipeline
experimental
Inspect the output size and recompute count of every stage.
Live example
Expected behavior
Filtering invalidates downstream stages, pagination invalidates only the final two, and column resizing leaves the row model cached.
Source
const api = createGrid({ rows, columns, pipeline: { filter: row => row.stock > 0 } });
api.on('rowModel:recomputed', ({ stages }) => console.log(stages));
console.log(api.getStageRows('filter'));const api = createGrid({ rows, columns, pipeline: { filter: row => row.stock > 0 } });
api.on('rowModel:recomputed', ({ stages }) => console.log(stages));
console.log(api.getStageRows('filter'));const api = createGrid({ rows, columns, pipeline: { filter: row => row.stock > 0 } });
api.on('rowModel:recomputed', ({ stages }) => console.log(stages));
console.log(api.getStageRows('filter'));const api = createGrid({ rows, columns, pipeline: { filter: row => row.stock > 0 } });
api.on('rowModel:recomputed', ({ stages }) => console.log(stages));
console.log(api.getStageRows('filter'));// JavaScript interop module
const api = createGrid({ rows, columns, pipeline: { filter: row => row.stock > 0 } });
api.on('rowModel:recomputed', ({ stages }) => console.log(stages));
console.log(api.getStageRows('filter'));API reference
| Kind | Name | Type | Description |
|---|---|---|---|
| Method | getRowModel | — | Reads the current outputs of the fixed seven-stage pipeline. |
| Method | getStageRows | — | Reads the immutable row list at one stage. |
| Event | rowModel:recomputed | — | Reports ordered stage names after actual computation. |