Use Efficient CSS Selectors (Deprecated)
What are CSS Selectors?
Why Use Efficient CSS Selectors?
There are several types of CSS selectors, such as universal, type, class, ID, and attribute. These, and various combinations, are all used to style how different elements will be displayed to the user. Like we have mentioned earlier in this guide, CSS and HTML can be called within HTML or through external files. The more CSS and rules applied to a page, the longer it will take the page to load, so make sure to review any outdate or unnecessary CSS files. The reason this message is deprecated is that it really is not an issue unless your page has many CSS selectors on it. Plus, browsers have become more efficient and faster, so this is not really a concern anymore. If your site utilizes a lot of CSS rules, you will want to review for efficiency and performance. Try to find a balance between style and performance.
Lighthouse is an open-source tool that is used to run an audit against your web pages and provides scores and suggestions for improving page performance, accessibility, SEO, and more.
PageSpeed Insights is a tool created by Google that reports on the performance of a page on both mobile and desktop devices, and provides suggestions on how that page may be improved.