Column virtualization
Only columns that intersect the horizontal viewport, plus a buffer, are rendered, both in the header and in every visible row. This keeps wide datasets with hundreds of columns usable. Variable column widths use a cumulative offset index so lookups stay logarithmic.
Planned. This page shows the specification from issue #183. The live example, source for every framework and the API reference replace it when the feature ships.
Live example
2,000 rows by 500 columns with mixed widths (60-240px). A readout shows rendered columns per row and the first and last rendered column index.
Expected behavior
The rendered column count tracks the viewport width plus overscan. Header and body cells stay pixel-aligned at every horizontal offset. Turning column virtualization off renders all columns, and the readout shows the difference.
Planned API surface
columnVirtualizationcolumns[].widthgetRenderedColumnRange()onRenderedRangeChangeAcceptance criteria
- Rendered column cells per row are at most the visible columns plus 2*overscanColumns. (pending)
- Header cell left offsets equal body cell left offsets for the same column index, within 0.5px. (pending)
- The column offset lookup is binary search over a prefix-sum array, and this is documented as O(log n). (pending)
- Resizing a column updates the offsets of all following columns in a single layout pass. (pending)