Barry M. Wong

Barry M. Wong

UI Engineer + Designer


CSS Performance

September 7, 2013 at 5:02 pm | css

We’re all aware that there are ways to optimize javascript to run faster, but we often overlook that CSS has performance issues as well. With single page apps being the rage these days, this becomes more important. This was emphasized in a couple of my interviews.

Reflow vs. Repaint
Repaint has to do with the rerendering of an element on the page where it doesn’t not effect the layout. So if you change the background color or border. Reflow changes the layout. So if you changes the size of an element, modify class attributes, inline style attributes. This one is more costly because it causes a whole lot of other elements to be rerendered.

Topics to be discovered: