Socket
Book a DemoInstallSign in
Socket

@ifanrx/stylelint-config-standard-scss

Package Overview
Dependencies
Maintainers
5
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ifanrx/stylelint-config-standard-scss

An Stylelint shared standard configuration for SCSS.

latest
npmnpm
Version
2.1.0
Version published
Maintainers
5
Created
Source

说明

@ifanrx/stylelint-config-standard-scss 仅针对 SASS 项目。

如果是 CSS 项目,请使用 @ifanrx/stylelint-config-standard

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

同时支持两种 BEM 格式:

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

注意事项

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

使用方法

单独使用

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

Vue 项目中使用

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

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