selector-pseudo-element-disallowed-list
指定不允许的伪元素选择器的列表。
¥Specify a list of disallowed pseudo-element selectors.
a::before {}
/** ↑
* This pseudo-element selector */
该规则忽略了:
¥This rule ignores:
-
C 伪元素,即以单个冒号为前缀的伪元素
¥CSS2 pseudo-elements i.e. those prefixed with a single colon
-
使用变量插值的选择器,例如
::#{$variable} {}
¥selectors that use variable interpolation e.g.
::#{$variable} {}
message
次要选项 可以接受该规则的参数。
¥The message
secondary option can accept the arguments of this rule.
选项
¥Options
array|string|regex
:["array", "of", "unprefixed", /pseudo-elements/, "/regex/"]|"pseudo-element"|"/regex/"|/regex/
鉴于:
¥Given:
["before", "/^--my-/i"]
以下模式被视为问题:
¥The following patterns are considered problems:
a::before {}
a::--my-pseudo-element {}
a::--MY-OTHER-pseudo-element {}
以下模式不被视为问题:
¥The following patterns are not considered problems:
a::after {}
a::--not-my-pseudo-element {}