-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.scss-lint.yaml
238 lines (189 loc) · 5.76 KB
/
.scss-lint.yaml
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
linters:
# Include one space before any ! and no spaces after it, with `!important` and
# `!default` declarations
BangFormat:
enabled: true
space_before_bang: true
space_after_bang: false
# 'border: none' is ok
BorderZero:
enabled: true
convention: none
# Prefer hexadecimal color codes over color keywords
ColorKeyword:
enabled: true
# Don't prefer color literals (keywords or hexadecimal codes) to be used only
# in variable declarations
ColorVariable:
enabled: false
# Allow both // and /**/ comments types
Comment:
enabled: false
# Disallow "@debug"
DebugStatement:
enabled: true
# @extend must come first, then properties, then nested rulesets
DeclarationOrder:
enabled: true
# Disallow use of the same property more than once in the same ruleset
DuplicateProperty:
enabled: true
# Place @else statements on the same line as the preceding curly brace
ElsePlacement:
enabled: true
style: same_line
# Require an empty line between rulesets
EmptyLineBetweenBlocks:
enabled: true
ignore_single_line_blocks: false
# Disallow empty rulesets
EmptyRule:
enabled: true
# Require a newline at the end of the file
FinalNewline:
enabled: true
present: true
# Use the shortest possible hex value. #fff instead of #ffffff, #0099aa = #09a
HexLength:
enabled: true
style: short
# Require hex colors to be lowercase (if they include any of the letters a-f)
HexNotation:
enabled: true
style: lowercase
# Ensure hexadecimal colors are valid (either three or six digits).
HexValidation:
enabled: true
# Never use ID selectors
IdSelector:
enabled: true
# Allow `!important` (we need this for itcss trumps layer)
ImportantRule:
enabled: false
# Do not include leading underscores or filename extensions in the basenames
# of SCSS files that you import
ImportPath:
enabled: true
leading_underscore: false
filename_extension: false
# Use spaces for indentation
Indentation:
enabled: true
allow_non_nested_indentation: true
character: space
width: 4
# Do not include leading zero before decimal values less than 1
LeadingZero:
enabled: true
style: exclude_zero
# Disallow more than one ruleset with the same selector in the same file
MergeableSelector:
enabled: enable
force_nesting: true
# Functions, mixins, and variables should be declared with all lowercase
# letters and hyphens instead of underscores
NameFormat:
enabled: true
convention: hyphenated_lowercase
# Limit nesting depth
NestingDepth:
enabled: true
max_depth: 4
# @extend %placeholders, don't @extend .a-class
PlaceholderInExtend:
enabled: true
# Limit the number of properties in a rule set
PropertyCount:
enabled: false
# Don't require properties to be in alphabetical order (also possible to
# specify a specific order)
PropertySortOrder:
enabled: false
# Disallow unknown CSS property names
PropertySpelling:
enabled: true
extra_properties: []
# Configure which units are allowed for property values
PropertyUnits:
enabled: false
# Do not qualify type selectors
QualifyingElement:
enabled: true
allow_element_with_attribute: false
allow_element_with_class: false
allow_element_with_id: false
# Limit selector depth
SelectorDepth:
enabled: true
max_depth: 4
# Class convention as per Csswizardry flavour of BEM
# http://csswizardry.com/2013/01/mindbemding-getting-your-head-round-bem-syntax/
SelectorFormat:
enabled: true
convention: hyphenated_lowercase
class_convention: '^[a-z]([a-z0-9](_{2}[a-z0-9])?(\-{0,2})?)*[a-z0-9]$'
placeholder_convention: '^[a-z]([a-z0-9](_{2}[a-z0-9])?(\-{0,2})?)*[a-z0-9]$'
convention_explanation: should be written in lowercase with hyphens
class_convention_explanation: should be written in hyphenated BEM (Block Element Modifier) format
placehloder_convention_explanation: should be written in hyphenated BEM (Block Element Modifier) format
# margin: 1px not margin: 1px 1px 1px 1px;
Shorthand:
enabled: true
# Only one property per line
SingleLinePerProperty:
enabled: true
allow_single_line_rule_sets: false
# Rulesets with multiple (comma delimited) selectors must have each selector
# on a separate line
SingleLinePerSelector:
enabled: true
# rgb(0,0,0) not rgb(0, 0, 0)
SpaceAfterComma:
enabled: false
# margin: 0px not margin:0px
SpaceAfterPropertyColon:
enabled: true
# margin: 0px not margin : 0px
SpaceAfterPropertyName:
enabled: true
# Opening braces should be preceded by a single space
SpaceBeforeBrace:
enabled: true
allow_single_line_padding: false
# rgb(0,0,0) not rgb( 0,0,0 )
SpaceBetweenParens:
enabled: true
spaces: 0
# Use single quotes, not double quotes
StringQuotes:
enabled: true
style: single_quotes
# Every property value must end with a semicolon
TrailingSemicolon:
enabled: true
# Do not include unnecessary trailing zeros after a decimal point. 2em instead
# of 2.0em
TrailingZero:
enabled: true
# No unnecessary fractions: 1 not 1.0
UnnecessaryMantissa:
enabled: true
# Do not use parent selector references (&) when they would otherwise be
# unnecessary
UnnecessaryParentReference:
enabled: true
# URLs should not contain protocols or domain names
UrlFormat:
enabled: true
# url('example.com') not url(example.com)
UrlQuotes:
enabled: true
# Don't prefer literals to be used only in variable declarations
VariableForProperty:
enabled: false
# We'll change this when we switch from compass to autoprefixr
VendorPrefix:
enabled: false
# No units on zero values: 0 not 0px
ZeroUnit:
enabled: true