Skip to content

Latest commit

 

History

History
59 lines (39 loc) · 968 Bytes

File metadata and controls

59 lines (39 loc) · 968 Bytes

declaration-bang-space-before

Require a single space or disallow whitespace before the bang of declarations.

a { color: pink !important; }
/**             ↑
 * The space before this exclamation mark */

命令行中的 --fix 选项可以自动修复此规则报告的所有问题。

选项

string: "always"|"never"

"always"

There must always be a single space before the bang.

以下模式被视为违规:

a { color: pink!important; }
a { color: pink  ! important; }

以下模式被视为违规:

a { color: pink !important; }
a { color:pink ! important; }

"never"

There must never be whitespace before the bang.

以下模式被视为违规:

a { color : pink !important; }

以下模式被视为违规:

a { color: pink!important; }
a { color: pink! important; }