3.0.4 • Published 2 months ago

@anolilab/stylelint-config v3.0.4

Weekly downloads
8
License
MIT
Repository
github
Last release
2 months ago

Stylelint Config

Stylelint config enforcing an understandable and consistent code style.



Install

npm install --dev-save browserslist stylelint @anolilab/stylelint-config

Usage

If you don’t have a .stylelintrc.cjs, we will create the file for you after installing @anolilab/stylelint-config.

If you already have a .stylelintrc.cjs, then you can extend the .stylelintrc.cjs, with @anolilab/stylelint-config.

module.exports = {
    extends: [
        "@anolilab/stylelint-config",
    ]
};

For tailwind you need to extend the stylelint rules

module.exports = {
    extends: [
        "@anolilab/stylelint-config",
    ],
    rules: {
        // Only for Tailwind support
        "at-rule-no-unknown": [
            true,
            {
                ignoreAtRules: ["tailwind", "apply", "variants", "responsive", "screen", "@tailwind"],
            },
        ],
        "declaration-block-trailing-semicolon": null,
        "no-descending-specificity": null,
    },
};

Add this command to your package.json scripts section

  {
    "scripts": {
      "lint:css": "stylelint --config=./.stylelintrc.cjs '**/*.{js,jsx,tsx,ts,less,css,scss,sass}'",
      "lint:css:fix": "stylelint --config=./.stylelintrc.cjs '**/*.{js,jsx,tsx,ts,less,css,scss,sass}' --fix"
    }
  }

Note: this package use browserslist to detect the correct browserslist config.

Supported Node.js Versions

Libraries in this ecosystem make the best effort to track Node.js’ release schedule. Here’s a post on why we think this is important.

Contributing

If you would like to help take a look at the list of issues and check our Contributing guild.

Note: please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.

Credits

License

The anolilab javascript-style-guide is open-sourced software licensed under the MIT license

3.0.4

2 months ago

3.0.3

5 months ago

3.0.2

5 months ago

3.0.1

7 months ago

3.0.0

7 months ago

2.2.1

10 months ago

2.2.0

11 months ago

2.1.4

1 year ago

2.1.3

1 year ago

2.1.2

1 year ago

2.1.1

1 year ago

2.1.0

1 year ago

2.0.4

1 year ago

2.0.3

1 year ago

2.0.2

1 year ago

2.0.1

1 year ago

2.0.0

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago