Sunhyoup Lee walks through the one thread that runs JavaScript, styles, layout, paint, and events, with about 10 milliseconds per frame, half that on a 120Hz screen. Spend it better: split long tasks and yield with scheduler.yield(), batch events with debounce and throttle, prioritize by user impact, and defer the rest. Or hand it off to the compositor or a Worker. Interactive demos compare them.
The browser’s main thread is expensive
