Skip to content

dkrnl/stylelint-max-root-rules

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

stylelint-max-root-rules

Limit the count of root rules.

For example, the following patterns are considered violations:

.foo { }

.foo-bar { }

The following patterns are not considered violations:

.foo { 
    &-bar { }
}

Installation

  1. If you haven't, install [stylelint]:
npm install stylelint --save-dev
  1. Install stylelint-max-root-rules:
npm install stylelint-max-root-rules --save-dev

Usage

Add stylelint-max-root-rules to your stylelint config plugins array, then add rules you need to the rules list. All rules from stylelint-max-root-rules need to be namespaced with pitcher.

{
    "plugins": [
        "stylelint-max-root-rules"
    ],
    "rules": {
        "pitcher/max-root-rules": 1
    }
}

About

Limit the count of root rules.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published