Pattern: Unknown at-rule
Issue: -
Disallow unknown at-rules. Should be used instead of stylelint's at-rule-no-unknown.
@unknown (max-width: 960px) {}
/** ↑
* At-rules like this */
This rule is basically a wrapper around the mentioned core rule, but with added SCSS-specific @
-directives. So if you use the core rule, @if
, @extend
and other Sass-y things will get warnings.
The following patterns are considered warnings:
@unknown {}
The following patterns are not considered warnings:
@function foo () {}
@while ($i == 1) {}
@media (max-width: 960px) {}
@if ($i) {} @else {}
Given:
["/^my-/i", "custom"]
The following patterns are not considered warnings:
@my-at-rule "x.css";
@my-other-at-rule {}
@MY-OTHER-AT-RULE {}
@custom {}