I wonder if there is an transpiler that parses the classes and ids used in an HTML page and removes all classes and ids in CSS and JavaScript.
This would be interesting to further narrow down files by improving page performance.
I wonder if there is an transpiler that parses the classes and ids used in an HTML page and removes all classes and ids in CSS and JavaScript.
This would be interesting to further narrow down files by improving page performance.
As you said that a "small-scale" solution also suits you, I'll give you a tip using the Aba Coverage of DevTools
of Chrome. Google Link link
In Aba Coverage you can evaluate what code is actually in use, worth both CSS and JS. I left the comments in the image.
ThedetailisthatforexampleresponsiveCSSisonlymarkedGreenwhenitisactuallyactivated.Thisistheonlydrawbackofthistechnique,becauseyouhavetonavigatethepagetoseewhatisusedornot.NotethatasIsaidthereisno<h1>
inHTML,thentheCSSruleof<h1>
willneverturnGreen
Seethisotherimagewithalargerdocument!
AsIsaid,itisnottheperfectsolutionforlargeprojects,butifitisusedfromthestartandauditingrightinshortperiodsoftime,itispossibletocontrolwellwhatisactuallybeingusedandwhat"junk" is. ..
EDIT How to open ABA COVERAGE
ChromeExtension
IntheChromeWebStoreyou'llalsofindsomeextensionsthathelpyou link