-
Notifications
You must be signed in to change notification settings - Fork 0
/
.stylelintrc.cjs
48 lines (48 loc) · 1.07 KB
/
.stylelintrc.cjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
module.exports = {
// 注册 stylelint 的 prettier 插件
plugins: ['stylelint-prettier'],
// 继承一系列规则集合
extends: [
// standard 规则集合
'stylelint-config-standard',
// standard 规则集合的 scss 版本
'stylelint-config-standard-scss',
// 样式属性顺序规则
'stylelint-config-recess-order',
// 接入 Prettier 规则
'stylelint-config-prettier',
'stylelint-prettier/recommended'
],
// 配置 rules
rules: {
"selector-class-pattern": "^\.[a-z]+(?:-[-a-z]+)?(?:--[a-z]+)?$",
"at-rule-no-unknown": [
true,
{
"ignoreAtRules": [
"tailwind",
"layer",
"apply",
"variants",
"responsive",
"screen"
]
}
],
"scss/at-rule-no-unknown": [
true,
{
"ignoreAtRules": [
"tailwind",
"layer",
"apply",
"variants",
"responsive",
"screen"
]
}
],
// 开启 Prettier 自动格式化功能
'prettier/prettier': true,
}
};