← Back to context

Comment by alwillis

8 hours ago

> Meanwhile, in any other formal language (including JS and CSS!), the standard assumption is that syntax errors are fatal,

In CSS, a syntax error isn't fatal. Most of the time, an unrecognized property causes that selector and all its properties to be ignored.

:is() and :where() support forgiving selector list [1].

Only the erroneous properties are ignored; the rest work normally.

[1]: https://drafts.csswg.org/selectors-4/#typedef-forgiving-sele...