Search

Real-World Usage of content-visibility

Jeremey Keith uses the little-used CSS property content-visibility to improve the performance on a fairly heavy page.

It works a treat. I did a before-and-after check with pagespeed insights on the page for Out On The Ocean. The “style and layout” part of the main thread work went down considerably. Total blocking time went from more than 600 milliseconds to less than 400 milliseconds.

Not a bad result for a little bit of CSS!

That’s what I’d like to see in more guest writing around here: explanations of real-world implementations to make websites better.

Need to learn about web performance?

Frontend Masters logo

We have an in-depth course all about Web Performance Fundamentals from Todd Gardner. There is a lot to know, from the psychology of web performance, to measuring the new Core Web Vitals, to building a culture of performance at your organization.

Leave a Reply

Your email address will not be published. Required fields are marked *