sasstools / sass-lint

Pure Node.js Sass linting
MIT License
1.77k stars 530 forks source link

Add array support for class-name-format conventions #1262

Open robbymarston opened 5 years ago

robbymarston commented 5 years ago

I'm working in a project that uses multiple JavaScript frameworks (Vue and React) in different areas of the application. As such, we're using a mix of BEM and CSS Modules that require different class name format conventions (hyphenated and camelcase respectively). Ideally, I could configure sass-lint to support both conventions via an array in my sass-lint.yml file.

class-name-format:
   - 1
   - convention:
      - hyphenatedbem
      - camelcase

Alternatively, I wouldn't be opposed to using a 'mixed' setting that supports any valid convention.

class-name-format:
   - 1
   - convention: mixed