Fastdom is a task scheduler and rendering optimizer designed to prevent layout thrashing by batching document reads and writes. It functions as a coordination system that separates document measurements and mutations into distinct queues, ensuring that asynchronous operations are executed in a way that minimizes browser reflows.
The project provides a performance profiling capability that detects improper document API access. By enforcing strict execution phases, it identifies layout thrashing bottlenecks and flags unauthorized DOM access occurring outside of the coordinated batching cycles.
The system manages the rendering workflow by aligning execution cycles with the browser refresh rate. It includes capabilities for grouping read-only operations and write operations, as well as a mechanism for cancelling pending tasks using unique identifiers.
The scheduler can be extended via a plugin system to add custom task types to the global execution pipeline.