@davidsneighbour/stylelint-config
v2026.0.2
Published
Stylelint configuration for use in @davidsneighbour projects.
Readme
Stylelint
Add the configuration to your repository (for instance in .stylelintrc or .stylelintrc.json or the stylelint parameter in package.json):
{
"extends": "@davidsneighbour/stylelint-config"
}To change parts of the configuration use the rules parameter.
{
"extends": "@davidsneighbour/stylelint-config",
"rules": {
"max-nesting-depth": null
}
}Add scripts to your package.json:
{
"scripts": {
"lint:styles": "stylelint assets/scss/",
"lint:styles:fix": "stylelint assets/scss/ --fix",
"lint:styles:config": "stylelint --print-config index.js"
}
}Exchange the assets/scss/ with your own styles folder.
Usage
Run stylelint and show errors and warnings:
npm run stylelintRun stylelint and fix automatically fixable issues:
npm run stylelint:fixPrint the current stylelint configuration:
npm run stylelint:configAll configurations
| Configurations | | | | --- | --- | --- | | Build Tools | | | | Babel | Webpack | | | Testing | | | | Cypress | HTML Validate | | | Linters and Formatters | | | | Browserslist | ESLint | PostCSS | | Prettier | Stylelint | | | Project Management | | | | Commitlint | Release | | | Markdown and Writing | | | | Markdownlint | Remark Lint | | | Other Tools | | | | Bootstrap | Tools | |
