gruntjs - stylelint-selector-bem-pattern BEM linter not working -


in gruntfile

stylelint: {     all: ['app/styles/**/*.scss'] }, 

.stylelintrc

{     "plugins": [         "stylelint-selector-bem-pattern"     ],     "rules": {       "plugin/selector-bem-pattern": {       "componentname": "[a-z]+",       "componentselectors": {         "initial": "^\\.{componentname}(?:-[a-z]+)?$",         "combined": "^\\.combined-{componentname}-[a-z]+$"       },       "utilityselectors": "^\\.util-[a-z]+$"     }     } } 

/users/jitendravyas/app-test/styles/components/_campaign-settings-integrations.scss

/* @define campaign-settings */  .campaign-settings__integrations {   @include flex; }  .campaign-settings__integration {   border: 1px solid $color-green;   border-radius: 3px;   color: $color-green;   margin-right: $base-spacing-unit;   @include flex;    .check {     background: $color-green;     color: white;     @include vertical-center;   }    > div {     padding: $half-spacing-unit;   } } 

not getting error when run stylelint. stylelint working other rules.

i believe have incorrectly defined component name. such, linter correctly skipping on file.

you must use either concise or verbose syntax:

/** @define campaign-settings */ 

or

/* postcss-bem-linter: define campaign-settings */ 

at moment appear use invalid form of concise syntax i.e. comment begins /*, rather /**.


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -