.gitignore added
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / stylelint / lib / rules / declaration-block-trailing-semicolon / README.md
1 # declaration-block-trailing-semicolon
2
3 Require or disallow a trailing semicolon within declaration blocks.
4
5 ```css
6 a { background: orange; color: pink; }
7 /**                                ↑
8  *                    This semicolon */
9 ```
10
11 The trailing semicolon is the *last* semicolon in a declaration block and it is optional.
12
13 This rule will ignore Less mixins, trailing `//` comments, and declaration blocks containing nested (at-)rules.
14
15 ## Options
16
17 `string`: `"always"|"never"`
18
19 ### `"always"`
20
21 There *must always* be a trailing semicolon.
22
23 The following patterns are considered violations:
24
25 ```css
26 a { color: pink }
27 ```
28
29 ```css
30 a { background: orange; color: pink }
31 ```
32
33 ```css
34 a { @include foo }
35 ```
36
37 The following patterns are *not* considered violations:
38
39 ```css
40 a { color: pink; }
41 ```
42
43 ```css
44 a { background: orange; color: pink; }
45 ```
46
47 ```css
48 a { @include foo; }
49 ```
50
51 ### `"never"`
52
53 There *must never* be a trailing semicolon.
54
55 The following patterns are considered violations:
56
57 ```css
58 a { color: pink; }
59 ```
60
61 ```css
62 a { background: orange; color: pink; }
63 ```
64
65 The following patterns are *not* considered violations:
66
67 ```css
68 a { color: pink }
69 ```
70
71 ```css
72 a { background: orange; color: pink }
73 ```