Compositing & Frames

Frame budget (60fps)

To hit 60 frames per second, the browser has roughly 16 ms per frame for JS, style, layout, paint, and composite combined. Overrun it and frames drop.

A single 50 ms task exceeds the 16 ms budget and costs about two or three frames.

work per frame16 ms budget
8 ms task → fits the frame
Watch a 50 ms task drop a frame

One of 40 cards in the JavaScript deck. Browse every card.