Skip to content

at-rule-no-deprecated

Reports a deprecated at-rule (@document, @nest, @viewport).

A deprecated at-rule was removed or is being removed from browsers, so a stylesheet that depends on it stops working there. A replacement exists or the feature was dropped.

To fix, use the replacement named in the specification, for example & nesting for @nest.

Reported
@nest a {}
...
css:
lint:
rules:
at-rule-no-deprecated:
level: warn # off (default), warn, error
options:
ignore: []
less:
lint:
rules:
at-rule-no-deprecated:
level: warn # off (default), warn, error
options:
ignore: []
scss:
lint:
rules:
at-rule-no-deprecated:
level: warn # off (default), warn, error
options:
ignore: []
Option Type Default Description
ignore list [] Names left out: names, or /regex/.

Enabled by the presets: css/stylelint-recommended.

Suppress one line with sudsy-disable-next-line at-rule-no-deprecated in a comment of the file’s language.

The same check in other tools; Sudsy reports what each upstream rule reports.

Tool Rule Match
stylelint at-rule-no-deprecated full