Duolith docs

Errors while checking a page

E0122 Style rule without a class

Message selector does not name a class, so it would reach outside this file

Words in italics are filled in when the compiler reports it, such as the element's name or the list of known ones.

Why

A <style> block's rules apply only to the file that writes them, by way of its classes. A selector made only of tags, *, or attributes would reach every element in the app.

How to fix it

Give the elements a class and select it, for example .label or .card span.

In a terminal

duolith explain E0122

Mentioned in