- Based on Stylelint v16
- Support lint Sass language (extend stylelint-config-standard-scss)
- Support lint HTML files (extend stylelint-config-html)
- Support lint Vue files (including Sass, extend stylelint-config-html)
- Support Tailwind rules
- Support UnoCSS rules
- Logical sorting properties (extend stylelint-config-clean-order)
- Reasonable defaults, best practices, only one-line of config
Requirements
- Stylelint v16.0.0 and above
yarn add -D @cedric-ruiu/stylelint-config
{
"extends": "@cedric-ruiu/stylelint-config"
}
Install Stylelint extension and create .vscode/settings.json
{
"prettier.enable": false,
"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
"source.fixAll.stylelint": "explicit",
"source.organizeImports": "never"
},
"css.validate": false,
"scss.validate": false,
"stylelint.enable": true,
"stylelint.packageManager": "yarn",
"stylelint.snippet": ["css", "postcss", "scss", "html", "vue"],
"stylelint.validate": ["css", "postcss", "scss", "html", "vue"],
}