ligershark / WebOptimizer

A bundler and minifier for ASP.NET Core
Apache License 2.0
750 stars 113 forks source link

CSS minifier fails to parse nested @starting-style CSS at-rule #301

Open AderitoSilva opened 4 months ago

AderitoSilva commented 4 months ago

The CSS minifier treats nested @starting-style CSS at-rules as invalid CSS, and thus fails to minify CSS files that contain such rules.

An example case would be the following:

.my-active-class {
    color: red;
    @starting-style {
        color: green;
    }
}

The @starting-style CSS at-rule is still experimental, but using it in its nested form breaks parsing for the whole file.