css/no-length-zero-unit
disallow units for zero lengths
- ⚙️ This rule is included in
"plugin:css/standard"
. - 🔧 The
--fix
option on the command line can automatically fix some of the problems reported by this rule.
📖 Rule Details
This rule reports a length of 0
with unit.
This rule was inspired by Stylelint's length-zero-no-unit rule.
🔧 Options
json
{
"css/no-length-zero-unit": ["error", {
"ignoreProperties": [],
"ignoreFunctions": [],
"ignoreCustomProperties": false,
}]
}
ignoreProperties
... You can specify property names or patterns that you want to ignore from checking.ignoreFunctions
... You can specify function names or patterns that you want to ignore from checking.ignoreCustomProperties
... Iftrue
, ignores custom properties from checking. Default isfalse
.
📚 Further reading
🚀 Version
This rule was introduced in eslint-plugin-css v0.1.0