Socket
Book a DemoInstallSign in
Socket

@ifanrx/stylelint-config-standard-bem

Package Overview
Dependencies
Maintainers
5
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ifanrx/stylelint-config-standard-bem

An Stylelint shared standard configuration for BEM.

latest
npmnpm
Version
2.1.0
Version published
Maintainers
5
Created
Source

说明

@ifanrx/stylelint-config-standard-bem 已默认在 @ifanrx/stylelint-config-standard@ifanrx/stylelint-config-standard-scss 中引入。

同时支持两种 BEM 格式:

  • 一般情况下,必须优先使用常规 BEM 格式:.block-foo__element-bar--modifier-baz
  • 如果使用 css module 或一些 css-in-js 的项目,通常使用驼峰式 BEM 格式:.blockFoo__elementBar_modifierBaz

注意事项

.stylelintrc.js 配置文件的 extends 中,@ifanrx/stylelint-config-standard-bem 总是放在最后一个。

使用方法

pnpm install @ifanrx/stylelint-config-standard-bem -D
// .stylelintrc.js
module.exports = {
  extends: [
    ...,
    '@ifanrx/stylelint-config-standard-bem'
  ],
}

Keywords

stylelint

FAQs

Package last updated on 28 Mar 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts