4.11.0 ⢠Published 3 months ago
@w0s/stylelint-config v4.11.0
stylelint-config
Stylelint configuration file used on my personal website (w0s.jp
).
Features
It is based on stylelint-config-standard
with its own rule settings.
š: No problem, š: Warning, šØ: Error
- Do not use ID selector.
- šØ
#foo {}
- š
.foo {}
- šØ
- Do not use multiple universal selectors. However, this excludes the use of a next-sibling combinator (
+
).- š
* {}
- šØ
* > * {}
- š
* + * {}
(This is used in the "owl selector" in stack layout)
- š
- CSS nesting must use the
&
nesting selector.- šØ
.foo { .bar {} }
- š
.foo { &.bar {} }
- šØ
- Disallow
!important
within declarations.- š
color: #000 !important
- š
color: #000
- š
- The order of properties within declaration blocks follows
stylelint-config-concentric-order
.- šØ
.foo { padding: 1em; margin: 1em }
- š
.foo { margin: 1em; padding: 1em }
- šØ
- Multi-keyword syntax is recommended for the
display
property. Thestylelint-display-multi-keyword
plugin is used.- š
display: block
- š
display: block flow
- š
- Use of CSS physical properties and values is not recommended. Use logical properties and values. The
stylelint-plugin-logical-css
plugin is used.- š
margin-top: 1em
- š
margin-block-start: 1em
- š
text-align: right
- š
text-align: end
- š
overflow-x: visible
(Theoverflow-*
logical properties is not well supported by browsers)
- š
- Use of CSS physical utils is not recommended. Use logical utils. The
stylelint-plugin-logical-css
plugin is used.- š
inline-size: 100lvw
- š
inline-size: 100lvi
- š
- Disallow default viewport-percentage units. The
stylelint-no-default-viewport
plugin is used.- šØ
inline-size: 10vi
- š
inline-size: 10lvi
- šØ
- The
font-weight
value must be numbers.- šØ
font-weight: normal
- š
font-weight: 500 /* Windows + Yu Gothic measures to be greater than 400 */
- šØ
- For the root element,
color
andbackground-color
must be specified as a set. Seestylelint-root-colors
for details.- šØ
:root { color: #000 }
- š
:root { background-color: #fff; color: #000 }
- šØ
See source code for other details.
Usage
{
"extends": ["@w0s/stylelint-config"]
}
4.11.0
3 months ago
4.10.0
4 months ago
4.9.0
5 months ago
4.8.0
10 months ago
4.7.0
1 year ago
4.6.0
1 year ago
4.5.1
1 year ago
4.5.0
1 year ago
4.4.0
1 year ago
4.3.0
1 year ago
4.1.0
1 year ago
4.2.0
1 year ago
4.1.1
1 year ago
4.0.1
1 year ago
4.0.0
1 year ago
2.0.2
1 year ago
3.0.0
1 year ago
2.0.1
1 year ago
2.0.0
1 year ago
1.2.1
2 years ago
1.2.0
2 years ago
1.1.0
2 years ago
1.0.2
3 years ago