.gitignore added
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / stylelint / lib / rules / function-comma-newline-before / README.md
1 # function-comma-newline-before
2
3 Require a newline or disallow whitespace before the commas of functions.
4
5 ```css
6   a { transform: translate(1
7     , 1) }
8 /** ↑
9  * These commas */
10 ```
11
12 ## Options
13
14 `string`: `"always"|"always-multi-line"|"never-multi-line"`
15
16 ### `"always"`
17
18 There *must always* be a newline before the commas.
19
20 The following patterns are considered violations:
21
22 ```css
23 a { transform: translate(1,1) }
24 ```
25
26 ```css
27 a { transform: translate(1 ,1) }
28 ```
29
30 ```css
31 a { transform: translate(1,
32   1) }
33 ```
34
35 The following patterns are *not* considered violations:
36
37 ```css
38 a {
39   transform: translate(1
40     ,1)
41 }
42 ```
43
44 ```css
45 a {
46   transform: translate(1
47     , 1)
48 }
49 ```
50
51 ### `"always-multi-line"`
52
53 There *must always* be a newline before the commas in multi-line functions.
54
55 The following patterns are considered violations:
56
57 ```css
58 a { transform: translate(1,
59   1) }
60 ```
61
62 The following patterns are *not* considered violations:
63
64 ```css
65 a { transform: translate(1,1) }
66 ```
67
68 ```css
69 a { transform: translate(1 ,1) }
70 ```
71
72 ```css
73 a {
74   transform: translate(1
75     ,1)
76 }
77 ```
78
79 ```css
80 a {
81   transform: translate(1
82     , 1)
83 }
84 ```
85
86 ### `"never-multi-line"`
87
88 There *must never* be a whitespace before the commas in multi-line functions.
89
90 The following patterns are considered violations:
91
92 ```css
93 a { transform: translate(1 ,
94   1) }
95 ```
96
97 The following patterns are *not* considered violations:
98
99 ```css
100 a { transform: translate(1 ,1) }
101 ```
102
103 ```css
104 a { transform: translate(1 , 1) }
105 ```
106
107 ```css
108 a {
109   transform: translate(1,
110     1)
111 }
112 ```