-
Notifications
You must be signed in to change notification settings - Fork 1
/
default.fclint.json
288 lines (288 loc) · 11.4 KB
/
default.fclint.json
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
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
{
"_patterns": {
"hasBooleanPrefix": "^(is|has|show|hide)",
"endsWithDateTime": "([Dd]ate|[Tt]ime)$",
"endsWithImage": "[Ii]m(age|g)$",
"endsWithNavigationMenu": "([Nn]av(igation)?|[Mm]enu)$",
"endsWithUriUrlLink": "([Uu]r[il]|[Ll]ink)$",
"kebabCase": "^([a-z0-9]+-)*[a-z0-9]*$",
"lowerCamelCase": "^[a-z][a-zA-Z0-9]*$",
"noNumbers": "^[^0-9]$",
"noNumberSuffix": "[^0-9]+$",
"snakeCase": "^([a-z0-9]+_)*[a-z0-9]*$"
},
"files": {
"ignorePatterns": []
},
"component": {
"requireFixtureFile": {
"check": false,
"severity": "major"
},
"requireStrictComponentStructure": {
"check": true,
"severity": "blocker"
},
"requireDocumentation": {
"check": false,
"severity": "major"
},
"requireDocumentationWithFixtureFile": {
"check": true,
"severity": "major"
}
},
"params": {
"count": {
"max": 20,
"min": 0,
"severity": "major"
},
"extraNamingConventionsPerType": {
"boolean": {
"typeValue": "boolean",
"namingConventions": ["hasBooleanPrefix"],
"severity": "minor"
}
},
"generalNamingConventions": {
"namingConventions": ["lowerCamelCase", "noNumberSuffix"],
"severity": "major"
},
"nameLength": {
"min": 3,
"max": 40,
"allowed": ["id"],
"denied": ["data", "row", "result", "results", "resultset"],
"severity": "major"
},
"requireDescription": {
"check": false,
"severity": "minor"
},
"requireDescriptionForType": {
"array": {
"typeValue": "array",
"requireDescription": true,
"severity": "minor"
},
"object": {
"typeValue": "object",
"requireDescription": true,
"severity": "minor"
}
},
"requireNamespaceWithoutLeadingSlash": {
"check": true,
"severity": "info"
},
"typeHints": {
"endsWithDateTime": {
"namePattern": "endsWithDateTime",
"typeHint": "SMS\\FluidComponents\\Domain\\Model\\DateTime",
"message": "It is recommended to use %s for date and time values",
"severity": "info"
},
"endsWithImage": {
"namePattern": "endsWithImage",
"typeHint": "Image",
"message": "It is recommended to use %s for images",
"severity": "info"
},
"endsWithNavigationMenu": {
"namePattern": "endsWithNavigationMenu",
"typeHint": "Navigation",
"message": "It is recommended to use %s for navigations",
"severity": "info"
},
"endsWithUriUrlLink": {
"namePattern": "endsWithUriUrlLink",
"typeHint": "Typolink",
"message": "It is recommended to use %s for urls",
"severity": "info"
},
"hasBooleanPrefix": {
"namePattern": "hasBooleanPrefix",
"typeHint": "boolean",
"message": "Based on its name, the parameter looks like a boolean",
"severity": "info"
}
},
"typeAlternatives": {
"array": {
"typeValue": "array",
"message": "It is recommended to use data structures or scalar types in combination with \"[]\" instead of generic \"%2$s\"",
"severity": "info"
},
"bool": {
"typeValue": "bool",
"typeAlternative": "boolean",
"message": "It is recommended to use %1$s instead of %2$s",
"severity": "info"
},
"DateTime": {
"typeValue": "DateTime",
"typeAlternative": "SMS\\FluidComponents\\Domain\\Model\\DateTime",
"message": "You should use %1$s instead of %2$s",
"severity": "minor"
},
"int": {
"typeValue": "int",
"typeAlternative": "integer",
"message": "It is recommended to use %1$s instead of %2$s",
"severity": "info"
},
"object": {
"typeValue": "object",
"message": "It is recommended to use specific data structures instead of generic \"%2$s\"",
"severity": "info"
}
}
},
"renderer": {
"requireClass": {
"check": true,
"severity": "minor"
},
"requireComponentPrefixer": {
"check": true,
"severity": "minor"
},
"requireRawContent": {
"check": true,
"severity": "minor"
},
"viewHelperRestrictions": {
"f:base": {
"viewHelperName": "f:base",
"message": "The base tag (<%s>) must not be used within components",
"severity": "major"
},
"f:be.*": {
"viewHelperName": "f:be.",
"message": "The backend ViewHelpers (<%s>) should not be used within components",
"severity": "minor"
},
"f:cache.*": {
"viewHelperName": "f:cache.",
"message": "The caching ViewHelpers (<%s>) should not be used within components",
"severity": "minor"
},
"f:cObject": {
"viewHelperName": "f:cObject",
"message": "TypoScript content must be passed as a component parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:debug": {
"viewHelperName": "f:debug",
"message": "<%s> may be used in components, but should not be used in production",
"severity": "info"
},
"f:flashMessages": {
"viewHelperName": "f:flashMessages",
"message": "Flash messages must be passed as a component parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:form": {
"viewHelperName": "f:form",
"message": "Form ViewHelpers (<%s>) may be used deliberately within components",
"severity": "info"
},
"f:form.*": {
"viewHelperName": "f:form.",
"message": "Form ViewHelpers (<%s>) may be used deliberately within components",
"severity": "info"
},
"f:format.html": {
"viewHelperName": "f:format.html",
"message": "<%1$s> must be used outside of the component, <f:format.raw> may be used within component to render HTML previously passed through <%1$s>",
"severity": "major"
},
"f:image": {
"viewHelperName": "f:image",
"message": "<%s> should be used deliberately within components (e. g. only in Atom.Image)",
"severity": "minor"
},
"f:inline": {
"viewHelperName": "f:inline",
"message": "Inline fluid code (<%s>) may be used deliberately within components",
"severity": "info"
},
"f:layout": {
"viewHelperName": "f:layout",
"message": "Layouts (<%s>) are currently not supported within components and thus must not be used",
"severity": "major"
},
"f:link.*": {
"viewHelperName": "f:link.",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:media": {
"viewHelperName": "f:media",
"message": "<%s> should be used deliberately within components (e. g. only in Atom.Media)",
"severity": "minor"
},
"f:render": {
"viewHelperName": "f:render",
"message": "Rendering sections or partials (<%s>) is currently not supported within components and thus must not be used",
"severity": "major"
},
"f:renderChildren": {
"viewHelperName": "f:renderChildren",
"message": "Widgets should be part of integration: <%s>",
"severity": "minor"
},
"f:section": {
"viewHelperName": "f:section",
"message": "Sections (<%s>) are currently not supported within components and thus must not be used",
"severity": "major"
},
"f:security.*": {
"viewHelperName": "f:security.",
"message": "Frontend user logic must happen outside of components and then passed as a parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:translate": {
"viewHelperName": "f:translate",
"message": "<%s> may be used within components, try to pass translations via component parameters instead",
"severity": "info"
},
"f:uri.action": {
"viewHelperName": "f:uri.action",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:uri.email": {
"viewHelperName": "f:uri.email",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:uri.external": {
"viewHelperName": "f:uri.external",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:uri.page": {
"viewHelperName": "f:uri.page",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:uri.typolink": {
"viewHelperName": "f:uri.typolink",
"message": "URIs must be generated outside of components and then passed as TypoLink parameter instead of using a ViewHelper: <%s>",
"severity": "major"
},
"f:uri.image": {
"viewHelperName": "f:uri.image",
"message": "<%s> should be used deliberately within components (e. g. only in Atom.Image)",
"severity": "minor"
},
"f:widget.*": {
"viewHelperName": "f:widget.",
"message": "Widgets should be part of integration: <%s>",
"severity": "minor"
}
}
}
}