0.2.0 • Published 3 years ago
stylelint-config-gy v0.2.0
说明
如果同时使用eslint+prettier,建议直接安装:
Installation
# 需要同时安装stylelint
npm i -D stylelint stylelint-config-gy
# 如果想要更好的体验,建议同时安装以下包:
npm i -D stylelint-config-prettier stylelint-config-recess-order stylelint-config-standard
Usage
Edit package.json
{
// ...
"stylelint": {
"extends": [
"stylelint-config-gy",
"stylelint-config-prettier",
"stylelint-config-standard",
"stylelint-config-recess-order"
]
},
}
配置项:
rules: {
"number-leading-zero": null,
"color-hex-case": "lower",
"color-hex-length": null,
"color-no-invalid-hex": true,
"rule-empty-line-before": null,
"unit-whitelist": ["em", "rem", "%", "s", "px", "deg"],
"declaration-colon-newline-after": null,
"declaration-block-trailing-semicolon": null,
"block-no-empty": null,
"declaration-colon-space-after": "always",
"max-empty-lines": 2,
"comment-empty-line-before": null,
"at-rule-empty-line-before": null,
"no-descending-specificity": null,
},