Closed HaSistrunk closed 3 years ago
Stylelint's selector-class-pattern prevents a BEM selector naming approach because it requires hyphens only.
Example linting error for selector .breadcrumbs__item:
.breadcrumbs__item
Selector should be written in lowercase with selector-class-pattern hyphens
We can adjust the linting rules selector-class-pattern in stylelintrc.json to allow BEM selector naming. We can specify new rules using regex.
stylelintrc.json
Describe the bug
Stylelint's selector-class-pattern prevents a BEM selector naming approach because it requires hyphens only.
Example linting error for selector
.breadcrumbs__item
:Additional context
We can adjust the linting rules selector-class-pattern in
stylelintrc.json
to allow BEM selector naming. We can specify new rules using regex.