Chrome DevTools: CSS Overview

I'm a full-stack developer from South Africa πΏπ¦. I love writing about JavaScript, HTML and CSS.
Search for a command to run...

I'm a full-stack developer from South Africa πΏπ¦. I love writing about JavaScript, HTML and CSS.
Glad you like it
Woaw! I might just get back to chrome because of this. Thanks for sharing Mr Chris. π―ππΎ
Thanks for sharing! I like the way all the colours are listed out, it's super easy to just get all a brand colour now
Most of you know me for my consistency, a golden arrow in my blog series. I've written 1000 articles in 1008 days! Almost an article a day, and my honeymoon was the only holiday I ever took. I'm super proud of this achievement; it has been a fantasti...

It's not the first time I'll be talking about community. I think it's an essential aspect of any successful tool. This shows in my previous explorations of Astro, Medusa, and now Vendure as well. All these products thrive in a super open, welcoming, ...

The cool part about Vendure is how easy it is to set up and how abstract each layer is. Basically, we get the following elements: External database Server Worker Admin UI Frontend While this is amazing, it also brings a bit of complexity when it co...

The previous article looked at customizing Vendure on a data and process level. In this article, we'll look at customizing emails, as they are often a big part of a webshop system. We'll be looking at two different layers of customization for customi...

Even though Vendure is a pretty significant project out of the box, in some cases, we might want to go in and modify some elements to work to our specific use case. In this article, I'll take a high-level look at some elements we can customize within...

I love how the Chrome dev team keeps making it easier and easier to identify potential issues on websites. Everything with improving speed and user experience.
The latest addition to these incredible tools is the "CSS Overview". This new feature is available as a preview in Chrome 96
First, we need to open the Chrome Dev Tools.
Mac
Cmd+Shift+Cor Windows:Ctrl+Shift+C.
Then click the "More options" button find, "More tools", and click CSS Overview.

Once you open the tool, you'll be prompted with an overview and some explanation of what it does. Click the capture button to start.

Once the tool is done, you'll see a mix of things returned. I'll break them down per chapter.
This high-level overview quickly shows you how many elements are found and how many selectors and stylesheets there are.

Then we get the colors panel, which shows all colors that were found on the page. This overview gives you a quick example to determine if these colors match your brand colors.

And show possible contrast issues.
The cool thing here is that you can click on each element to see all occurrences in the stylesheet.
In the image below, I clicked the #DEBFDE color, and you can see all elements that have this color.
You can then press each element to highlight it in the DOM.

Really find this a welcome addition to quickly see unwanted color styles, like white on white or hidden elements.
Then we enter the font overview panel, which shows all fonts you use on the page and their style.

I actually noticed through this tool I'm assigning different fonts on top elements, causing the font issue to go a bit wild.
Again, super easy to quickly identify weird are one-of-a-kind font sizes that might not be in line with your brand.
Then we have a panel on unused declarations, making it easy to find styles that will have no effect.

In my case, it's a pseudo selector setting vertical-align on an element that's not inline or a table-cell.
(This particular case is actually valid, so will log this with the DevTools team)
And then, we get an overview panel for our media queries. This makes it super easy to find all your queries.

Including screen sizes, preferred schemes, and more. You might find elements in there to optimize and combine queries that are about the same size.
I hope you enjoy this tool as much as I do. I really like to revamp my CSS to be smaller, more inline, and brand correct.
And this tool definitely helps with that π.
Thank you for reading my blog. Feel free to subscribe to my email newsletter and connect on Facebook or Twitter