Primer Stylelint Config
A sharable stylelint config object that enforces GitHub's css rules
$ npm install --save stylelint-config-primer
Within your stylelint config object You can extend this configuration. This will serve as a base for your config, then you can make overrides in your own config object.
This is a list of the lints turned on in this configuration, and what they do.
- comment-empty-line-before: There must always be an empty line before comments. Except: Comments that are nested and the first child of their parent node. Ignore: stylelint commands
- comment-whitespace-inside: There must always be whitespace inside the markers.
- declaration-property-value-blacklist: Specify a blacklist of disallowed property and value pairs within declarations.
^transition: Disallow the use of
all within transitions.
^background: Disallow the use of
http: protocols within background image urls.
^border: Disallow the use of the word
none for borders, use
.+: For everything ban the use of the word
Media Query List
- rule-nested-empty-line-before: There must always be an empty line before multi-line rules. Except: Nested rules that are the first of their parent rule. Ignore: Rules that come after a comment.
- rule-non-nested-empty-line-before: There must always be an empty line before multi-line rules. Ignore: Rules that come after a comment.
MIT © GitHub