@novicell/stylelint-config

0.2.10 • Public • Published

Novicell Stylelint config

npm

This is an Stylelint config for all projects written with either vanilla CSS or PostCSS.

How to install

  1. npm i stylelint @novicell/stylelint-config
  2. Create a .stylelintrc.json in the root of the project

  3. Add the following 👇

    {
      "extends": "@novicell/stylelint-config",
      "rules": {
        // Your project specific rules or overrides
      }
    }
  4. Add lint scripts to package.json

    "scripts": {
      "stylelint": "stylelint '**/*.{css,vue}'",
      "stylelint:fix": "stylelint '**/*.{css,vue}' --fix"
    }
  5. Make VS Code autofix issues on save (optional)

    • Install the Stylelint extension
    • Create a .vscode folder in root and add settings.json to it. Remember to disable Prettier!
    • Add the following
     {
       "css.validate": false,
       "less.validate": false,
       "scss.validate": false,
       "stylelint.validate": ["css", "postcss", "vue"],
       "editor.codeActionsOnSave": {
         "source.fixAll.stylelint": true,
       },
       "prettier.enable": false
     }
    
  6. Use StylelintWebPackPLugin. to fix your issues on build (optional)

Contribution

Looking to contribute something? Here's how you can help. Please take a moment to review our contribution guidelines in order to make the contribution process easy and effective for everyone involved.

License

The Novicell CSS Utils is licensed under the MIT license. (http://opensource.org/licenses/MIT)

Readme

Keywords

Package Sidebar

Install

npm i @novicell/stylelint-config

Weekly Downloads

13

Version

0.2.10

License

MIT

Unpacked Size

13.8 kB

Total Files

7

Last publish

Collaborators

  • emilras
  • heense
  • jhavmoeller
  • hotepp
  • emiank
  • ozzy1312
  • simoneldevig
  • emilostervig