-
Notifications
You must be signed in to change notification settings - Fork 18
Expand file tree
/
Copy pathstylelint.config.js
More file actions
30 lines (30 loc) · 1022 Bytes
/
Copy pathstylelint.config.js
File metadata and controls
30 lines (30 loc) · 1022 Bytes
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
// 与ESlint类似的CSS检测工具, 用于样式规范检查与修复 [官网] https://stylelint.io/
// vue项目中使用新的单文件组件样式的特性(状态驱动的动态 CSS | v-bind(var) )时,值需要用引号包裹起来,避免被stylelint所格式化
module.exports = {
root: true,
extends: [
'stylelint-config-recommended-scss',
'stylelint-config-recommended-vue',
'stylelint-config-prettier',
// 对css进行排序 → https://github.com/stormwarning/stylelint-config-recess-order/blob/main/index.js
'stylelint-config-recess-order',
],
rules: {
'no-empty-source': null,
'property-no-unknown':null,
'at-rule-no-unknown': null,
'no-descending-specificity': null,
'selector-pseudo-class-no-unknown':null,
'scss/at-import-partial-extension': null,
'scss/at-import-no-partial-leading-underscore': null,
},
ignoreFiles: [
'**/*.js',
'**/*.jsx',
'**/*.ts',
'**/*.tsx',
'dist/**',
'public/**',
'index.html',
],
}