Describe the bug
A CSS selector that only uses classes/tags/ids that occur in the content, but never matches, is not removed.
Example HTML:
<div class="div">div</div>
<span class="span">span</span>
CSS:
div.span {
color: #f00;
}
To Reproduce
- Copy the HTML and CSS from the example above.
- Invoke
purgecss
- Observe that it does not purge the CSS
Expected Behavior
The CSS ruleset does not match anything and should therefore be removed.
Environment
purgecss version 6.0.0
Add any other context about the problem here
No response
Code of Conduct
Describe the bug
A CSS selector that only uses classes/tags/ids that occur in the content, but never matches, is not removed.
Example HTML:
CSS:
To Reproduce
purgecssExpected Behavior
The CSS ruleset does not match anything and should therefore be removed.
Environment
purgecss version 6.0.0
Add any other context about the problem here
No response
Code of Conduct