-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.stylelintrc.js
63 lines (61 loc) · 1.65 KB
/
.stylelintrc.js
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
const { propertyGroups } = require('stylelint-config-clean-order');
const propertiesOrder = propertyGroups.map(properties => ({
noEmptyLineBetween: true,
emptyLineBefore: 'never',
properties
}));
module.exports = {
extends: ['stylelint-config-standard'],
customSyntax: 'postcss-less',
plugins: ['stylelint-order', 'stylelint-declaration-block-no-ignored-properties'],
rules: {
'function-no-unknown': null,
'no-descending-specificity': null,
'plugin/declaration-block-no-ignored-properties': true,
'selector-type-no-unknown': [
true,
{
ignoreTypes: ['/^g2-/', '/^nz-/', '/^app-/']
}
],
'selector-pseudo-element-no-unknown': [
true,
{
ignorePseudoElements: ['ng-deep']
}
],
'import-notation': 'string',
'media-feature-range-notation': 'prefix',
'media-query-no-invalid': null,
'order/order': [
[
'dollar-variables',
'at-variables',
'custom-properties',
{ type: 'at-rule', name: 'custom-media' },
{ type: 'at-rule', name: 'function' },
{ type: 'at-rule', name: 'mixin' },
{ type: 'at-rule', name: 'extend' },
{ type: 'at-rule', name: 'include' },
'declarations',
'less-mixins',
{
type: 'rule',
selector: /^&::[\w-]+/,
hasBlock: true
},
'rules',
{ type: 'at-rule', name: 'media', hasBlock: true }
],
{ severity: 'warning' }
],
'order/properties-order': [
propertiesOrder,
{
severity: 'warning',
unspecified: 'bottomAlphabetical'
}
]
},
ignoreFiles: ['src/assets/**/*']
};