Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
757 views
in Technique[技术] by (71.8m points)

Chrome devtools exported coverage JSON has all CSS and not only used

So I am currently trying to find a way to export only used CSS for my site.

After some reseach I found the chrome devtools coverage feature. It seems to work. It shows that only 1% of my CSS code is used for CSS code from external libraries, e.g. bootstrap and animate.css.

Now there is an export button, which generates a JSON file with the (so I thought) code which I use, but the code in the JSON file is the normal code I use, all 100% not the 1% I use. Whats the point of this feature then?

Now I know that I use only 1% of code, but cannot access it.

Any other ideas how to do it? Or do I not understand the purpose of devtools exported coverage JSON?

enter image description here

question from:https://stackoverflow.com/questions/66061837/chrome-devtools-exported-coverage-json-has-all-css-and-not-only-used

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...