-
-
Notifications
You must be signed in to change notification settings - Fork 27
/
package.json
336 lines (336 loc) · 14.4 KB
/
package.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
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
{
"name": "twig-language-2",
"displayName": "Twig Language 2",
"description": "Snippets, Syntax Highlighting, Hover, and Formatting for Twig",
"version": "0.9.4",
"publisher": "mblode",
"license": "MIT",
"author": {
"name": "Matthew Blode",
"email": "[email protected]",
"url": "https://matthewblode.com"
},
"homepage": "https://github.com/mblode/vscode-twig-language-2",
"bugs": {
"url": "https://github.com/mblode/vscode-twig-language-2/issues"
},
"repository": {
"type": "git",
"url": "https://github.com/mblode/vscode-twig-language-2.git"
},
"icon": "images/icon.png",
"engines": {
"vscode": "^1.30.0"
},
"categories": [
"Formatters",
"Programming Languages",
"Snippets",
"Other"
],
"keywords": [
"php",
"twig",
"snippets",
"craft",
"beautify"
],
"activationEvents": [
"onLanguage:twig"
],
"main": "./extension/index",
"contributes": {
"languages": [
{
"id": "twig",
"aliases": [
"HTML (Twig)",
"twig"
],
"extensions": [
".twig",
".html.twig"
],
"configuration": "./src/languages/twig.configuration.json"
}
],
"grammars": [
{
"language": "twig",
"scopeName": "text.html.twig",
"path": "./src/syntaxes/twig.tmLanguage",
"embeddedLanguages": {
"source.json": "json",
"source.css": "css",
"source.css.scss": "scss",
"source.js": "javascript",
"source.ts": "typescript"
}
}
],
"snippets": [
{
"language": "twig",
"path": "./src/snippets/snippets.json"
}
],
"configuration": {
"type": "object",
"title": "Twig Language 2",
"properties": {
"twig-language-2.hover": {
"type": "boolean",
"default": true,
"description": "Whether to enable/disable Twig hover."
},
"twig-language-2.formatting": {
"type": "boolean",
"default": true,
"description": "Whether to enable/disable Twig PrettyDiff formatting."
},
"twig-language-2.braceLine": {
"type": "boolean",
"default": false,
"description": "If true an empty line will be inserted after opening curly braces and before closing curly braces."
},
"twig-language-2.bracePadding": {
"type": "boolean",
"default": false,
"description": "Inserts a space after the start of a container and before the end of the container if the contents of that container are not indented; such as: conditions, function arguments, and escaped sequences of template strings."
},
"twig-language-2.braceStyle": {
"type": "string",
"enum": [
"collapse",
"collapse-preserve-inline",
"expand",
"none"
],
"default": "none",
"description": "Emulates JSBeautify's brace_style option using existing Pretty Diff options."
},
"twig-language-2.braces": {
"type": "boolean",
"default": false,
"description": "Determines if opening curly braces will exist on the same line as their condition or be forced onto a new line."
},
"twig-language-2.commentLine": {
"type": "boolean",
"default": false,
"description": "If a blank new line should be forced above comments."
},
"twig-language-2.comments": {
"type": "boolean",
"default": false,
"description": "This will determine whether comments should always start at position 0 of each line or if comments should be indented according to the code."
},
"twig-language-2.compressedCss": {
"type": "boolean",
"default": false,
"description": "If CSS should be beautified in a style where the properties and values are minifed for faster reading of selectors."
},
"twig-language-2.correct": {
"type": "boolean",
"default": false,
"description": "Automatically correct some sloppiness in code."
},
"twig-language-2.cssInsertLines": {
"type": "boolean",
"default": false,
"description": "Inserts new line characters between every CSS code block."
},
"twig-language-2.elseLine": {
"type": "boolean",
"default": false,
"description": "If else_line is true then the keyword 'else' is forced onto a new line."
},
"twig-language-2.endComma": {
"type": "string",
"enum": [
"always",
"never",
"none"
],
"default": false,
"description": "If there should be a trailing comma in arrays and objects. Value multiline only applies to modes beautify and diff."
},
"twig-language-2.forceAttribute": {
"type": "boolean",
"default": false,
"description": "If all markup attributes should be indented each onto their own line."
},
"twig-language-2.forceIndent": {
"type": "boolean",
"default": false,
"description": "Will force indentation upon all content and tags without regard for the creation of new text nodes."
},
"twig-language-2.formatArray": {
"type": "string",
"enum": [
"default",
"indent",
"inline"
],
"default": "default",
"description": "Determines if all array indexes should be indented, never indented, or left to the default."
},
"twig-language-2.formatObject": {
"type": "string",
"enum": [
"default",
"indent",
"inline"
],
"default": "default",
"description": "Determines if all object keys should be indented, never indented, or left to the default."
},
"twig-language-2.functionName": {
"type": "boolean",
"default": false,
"description": "If a space should follow a JavaScript function name."
},
"twig-language-2.indentStyle": {
"type": "string",
"enum": [
"space",
"tab"
],
"default": "tab",
"description": "Choose to indent using tabs or spaces. This formatter will not use the \"Editor: Insert Spaces\" setting, nor will it use the `indent_style` setting declared in `.editorconfig` files."
},
"twig-language-2.indentLevel": {
"type": "integer",
"default": 0,
"description": "How much indentation padding should be applied to beautification? This option is internally used for code that requires switching between libraries."
},
"twig-language-2.tabSize": {
"type": "integer",
"default": 0,
"description": "0 will default to the editor's tab size (`editor.tabSize`). This formatter will not use the `indent_size` setting declared in `.editorconfig` files."
},
"twig-language-2.methodChain": {
"type": "integer",
"default": 0,
"description": "When to break consecutively chained methods and properties onto separate lines. A negative value disables this option. A value of 0 ensures method chains are never broken."
},
"twig-language-2.neverFlatten": {
"type": "boolean",
"default": false,
"description": "If destructured lists in script should never be flattend."
},
"twig-language-2.newLine": {
"type": "boolean",
"default": true,
"description": "Insert an empty line at the end of output."
},
"twig-language-2.noCaseIndent": {
"type": "boolean",
"default": false,
"description": "If a case statement should receive the same indentation as the containing switch block."
},
"twig-language-2.noLeadZero": {
"type": "boolean",
"default": false,
"description": "Whether leading 0s in CSS values immediately preceeding a decimal should be removed or prevented."
},
"twig-language-2.objectSort": {
"type": "boolean",
"default": false,
"description": "Sorts markup attributes and properties by key name in script and style."
},
"twig-language-2.preserve": {
"type": "integer",
"default": 2,
"description": "The maximum number of consecutive empty lines to retain."
},
"twig-language-2.preserveComment": {
"type": "boolean",
"default": false,
"description": "Prevent comment reformatting due to option wrap."
},
"twig-language-2.quoteConvert": {
"type": "string",
"enum": [
"double",
"none",
"single"
],
"default": "none",
"description": "If the quotes of script strings or markup attributes should be converted to single quotes or double quotes."
},
"twig-language-2.space": {
"type": "boolean",
"default": true,
"description": "Inserts a space following the function keyword for anonymous functions."
},
"twig-language-2.spaceClose": {
"type": "boolean",
"default": false,
"description": "Markup self-closing tags end will end with ' />' instead of '/>'."
},
"twig-language-2.tagMerge": {
"type": "boolean",
"default": false,
"description": "Allows immediately adjacement start and end markup tags of the same name to be combined into a single self-closing tag."
},
"twig-language-2.tagSort": {
"type": "boolean",
"default": false,
"description": "Sort child items of each respective markup parent element."
},
"twig-language-2.ternaryLine": {
"type": "boolean",
"default": true,
"description": "If ternary operators in JavaScript ? and : should remain on the same line."
},
"twig-language-2.unformatted": {
"type": "boolean",
"default": false,
"description": "If markup tags should have their insides preserved. This option is only available to markup and does not support child tokens that require a different lexer."
},
"twig-language-2.variableList": {
"type": "string",
"enum": [
"each",
"list",
"none"
],
"default": "none",
"description": "If consecutive JavaScript variables should be merged into a comma separated list or if variables in a list should be separated."
},
"twig-language-2.vertical": {
"type": "boolean",
"default": false,
"description": "If lists of assignments and properties should be vertically aligned. This option is not used with the markup lexer."
},
"twig-language-2.wrap": {
"type": "integer",
"default": 0,
"description": "Character width limit before applying word wrap. A 0 value disables this option. A negative value concatenates script strings."
}
}
}
},
"capabilities": {
"hoverProvider": "true"
},
"scripts": {
"start": "rollup -c",
"build": "rollup -c",
"watch": "rollup -c -w"
},
"devDependencies": {
"@types/mocha": "^8.0.3",
"@types/node": "^14.6.0",
"eslint": "^7.7.0",
"eslint-config-prettier": "^6.11.0",
"typescript": "^4.0.2",
"vscode": "^1.1.37"
},
"dependencies": {
"prettydiff": "^101.2.6",
"rollup": "^2.26.5",
"rollup-plugin-babel": "^4.4.0",
"rollup-plugin-json": "^4.0.0"
}
}