.gitignore added
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / stylelint / lib / rules / function-whitelist / README.md
1 # function-whitelist
2
3 Specify a whitelist of allowed functions
4
5 ```css
6 a { transform: scale(1); }
7 /**            ↑
8  * These functions */
9 ```
10
11 ## Options
12
13 `array|string`: `["array", "of", "unprefixed", "functions" or "regex"]|"function"|"/regex/"`
14
15 If a string is surrounded with `"/"` (e.g. `"/^rgb/"`), it is interpreted as a regular expression.
16
17 Given:
18
19 ```js
20 ["scale", "rgba", "linear-gradient"]
21 ```
22
23 The following patterns are considered violations:
24
25 ```css
26 a { transform: rotate(1); }
27 ```
28
29 ```css
30 a {
31   color: hsla(170, 50%, 45%, 1)
32 }
33 ```
34
35 ```css
36 a {
37   background:
38     red,
39     -webkit-radial-gradient(red, green, blue);
40 }
41 ```
42
43 The following patterns are *not* considered violations:
44
45 ```css
46 a { background: red; }
47 ```
48
49 ```css
50 a { transform: scale(1); }
51 ```
52
53 ```css
54 a {
55   color: rgba(0, 0, 0, 0.5);
56 }
57 ```
58
59 ```css
60 a {
61   background:
62     red,
63     -moz-linear-gradient(45deg, blue, red);
64 }
65 ```