-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathstylelint.config.js
More file actions
57 lines (57 loc) · 1.8 KB
/
stylelint.config.js
File metadata and controls
57 lines (57 loc) · 1.8 KB
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
/** @type {import('stylelint').Config} */
export default {
extends: ['stylelint-config-standard'],
plugins: ['stylelint-order', 'stylelint-no-unsupported-browser-features'],
customSyntax: 'postcss-styled-syntax',
rules: {
'order/properties-alphabetical-order': true,
'no-duplicate-selectors': true,
'color-hex-length': 'short',
'selector-attribute-quotes': 'always',
'value-no-vendor-prefix': true,
'font-weight-notation': 'named-where-possible',
'font-family-name-quotes': 'always-unless-keyword',
'comment-whitespace-inside': 'always',
'comment-empty-line-before': null,
'rule-empty-line-before': [
'always-multi-line',
{
except: ['first-nested', 'after-single-line-comment'],
ignore: ['after-comment'],
},
],
'selector-pseudo-element-colon-notation': 'double',
'media-feature-name-no-vendor-prefix': true,
'no-descending-specificity': null,
'declaration-block-no-redundant-longhand-properties': null,
'plugin/no-unsupported-browser-features': [
true,
{
browsers: ['extends browserslist-config-baseline'],
ignore: [
'css3-cursors',
'intrinsic-width',
'css-resize',
'css-display-contents',
'css-subgrid',
'multicolumn',
'css-clip-path',
'css-masks',
],
},
],
'property-no-vendor-prefix': null,
'selector-class-pattern': [
'^([a-z][a-z0-9]*)((-{1,2}|_{1,2})[a-z0-9]+)*$',
{
message: 'Expected class selector to be either kebab-case, kebab--case or snake__case',
},
],
'selector-id-pattern': [
'^([a-z][a-z0-9]*)((-{1,2}|_{1,2})[a-z0-9]+)*$',
{
message: 'Expected id selector to be either kebab-case, kebab--case or snake__case',
},
],
},
};