Skip to content

Latest commit

 

History

History
38 lines (31 loc) · 1.12 KB

README.md

File metadata and controls

38 lines (31 loc) · 1.12 KB

stylelint-plugin-bem-style

A stylelint plugin that verifies the BEM style. Customized BEM style supported.

Installation

    npm install --save-dev stylelint-plugin-bem-style

Configuration

{
    "plugins": [
        "stylelint-plugin-bem-style"
    ]
}

this would use the standard BEM style.

Example

If you wanna use the customized BEM style defined by Tencent, use the configuration below.

{
    "plugins": [
        "stylelint-plugin-bem-style"
    ],
    "rules": {
        "plugin/bem-style": "B__E_M"
    }
}

Alternative

This plugin is designed to make the customization of BEM style possible.

Alternative plugins, like stylelint-selector-bem-pattern and @namics/stylelint-bem, can be used if you use the standard BEM style.