Skip to content

Instantly share code, notes, and snippets.

@sveggiani
Last active November 3, 2022 02:59
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save sveggiani/8628994e473ca559248917ef01000f6e to your computer and use it in GitHub Desktop.
Save sveggiani/8628994e473ca559248917ef01000f6e to your computer and use it in GitHub Desktop.
[Configure Stylelint + Prettier for SASS/SCSS] #javascript #prettier #stylelint #sass #scss #masscode
{
"name": "svod-fe-website",
"version": "0.1.0",
"devDependencies": {
"prettier": "^1.13.4",
"prettier-stylelint": "^0.4.2",
"stylelint": "^9.3.0",
"stylelint-config-sass-guidelines": "^5.0.0",
}
}
{
"extends": [
"stylelint-config-sass-guidelines",
"./node_modules/prettier-stylelint/config.js"
],
"rules": {
"color-hex-case": "upper",
"color-hex-length": "long",
"max-nesting-depth": 3,
"declaration-block-single-line-max-declarations": 1,
"declaration-block-semicolon-newline-after": "always-multi-line",
"number-leading-zero": "never",
"declaration-property-value-whitelist": {
"color": ["/^\\$|initial|inherit|transparent/"]
},
"order/order": [
[
{
"type": "at-rule",
"name": "include",
"hasBlock": false
},
"dollar-variables",
"custom-properties",
{
"type": "at-rule",
"name": "extend"
},
"declarations",
{
"type": "at-rule",
"name": "include",
"hasBlock": true
},
{
"type": "at-rule",
"name": "include",
"parameter": "breakpoint",
"hasBlock": true
},
"rules"
]
]
}
}
@yuceltoluyag
Copy link

https://marketplace.visualstudio.com/items?itemName=shinnn.stylelint - url dead

https://marketplace.visualstudio.com/items?itemName=stylelint.vscode-stylelint is true ?

@sveggiani
Copy link
Author

@yuceltoluyag These notes are quite old now. I don't know if the extension URL changed or this is a complete new extension but I'm now using the extension you mentioned.

@yuceltoluyag
Copy link

@yuceltoluyag These notes are quite old now. I don't know if the extension URL changed or this is a complete new extension but I'm now using the extension you mentioned.

my mistake, I commented by looking at the activity part :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment