STYLE003: empty-style-class
Style class defines no styles
| Code | STYLE003 |
| Name | empty-style-class |
| Category | Styles (STYLE) |
| Default severity | info |
| Enabled by default | yes |
| Fix available | no |
| ign-lint equivalent | none |
What it does
Section titled “What it does”Reports style classes whose base style and every variant (pseudo-class
and media-query variants) define no style properties and no animation.
Classes that the project stylesheet or a gateway theme uses in a selector
(.psc-<name>) are marker classes and are not reported.
Why is this bad?
Section titled “Why is this bad?”An empty style class does nothing: components that use it look exactly the same without it. It is usually a class whose styles were moved elsewhere, or a placeholder that was never filled in.
Example
Section titled “Example”{"base": {"style": {}}, "variants": []}Give the class styles, or delete it and remove it from the components that use it.
Generated from the rule metadata by iglint generate-docs; iglint rule STYLE003 prints the same page in the terminal. Source: docs/rules/STYLE003.md.