I have a lot of CSS files on the page. But a lot of these files are not used by styles. Is it possible to determine which files are used by page and which not.
3) If you use google chrome,then u can directly use Inspect Element option by right clicking on page. Show activity on this post. The way to find or access to CSS files are used for current page, could vary base on the Browser and/or Operating system you are using.
When you open the Console of the current browser, click on the element you want to inspect and on the right hand side you will have a tab name Styles as shows below: As you can see the image has the name of the CSS file (in this example named "desktop_ltr.css")
Google Chrome has a two ways to check for unused CSS. 1. Audit Tab: > Right Click + Inspect Element on the page, find the "Audit" tab, and run the audit, making sure "Web Page Performance" is checked.
Now you can remove those CSS files that are not used on that web page. Thanks. Show activity on this post. New in Chrome 59 is the coverage tool that shows you CSS and JS code coverage.
Use http://getfirebug.com/ to debug the page.
When looking at the css it will reference which stylesheet is used.
For example:
You can see from the screenshot that when using Firebug it shows in the blue text that the page is using the style.css
stylesheet.
Work down the tree in Firebug and simply hover over your elements and see which stylesheets are used.
You can debug with firebug ( http://getfirebug.com/ ). It will show what is used for what and allows you to find out.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With