Worker offloading candidates evaluation
This feature evaluates which work can move off the main thread into a Web Worker. Candidates are text width estimation for auto column width and row heights (via OffscreenCanvas measureText), row height prefix-sum rebuilding, and range computation for large datasets. DOM work stays on the main thread. The demo compares main-thread and worker modes with measured traces, and the findings decide whether each candidate…
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,000 rows with data-driven heights. A button triggers a full height index rebuild; worker offloading is off.
Expected behavior
In worker mode, the main thread stays interactive during the rebuild, with a progress indicator, and results apply atomically. If workers are blocked, the grid falls back to chunked main-thread work and fires onWorkerFallback. The trace comparison is displayed from real measurements.
Planned API surface
workerOffload.enabledworkerOffload.tasksworkerOffload.workerUrlonWorkerFallbackAcceptance criteria
- Worker results applied to the grid equal the main-thread results (verified by equality test). (pending)
- Fallback to main-thread chunked processing occurs automatically when a worker fails to start. (pending)
- Text estimates in the worker are marked as estimates and are corrected by DOM measurement. (pending)
- An evaluation report lists each candidate with its measured benefit, complexity and a ship/no-ship decision. (pending)