[XML] Use the same HTML language configuration for XML

This PR is a copy/paste of the HTML language configuration to have for instance autoClosingPairs for Comments and adds autoClosingPairs for CDATA.
This commit is contained in:
Angelo 2019-07-22 13:34:55 +02:00 committed by GitHub
parent 4deeb958f2
commit ce7f99fa96
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,31 +1,34 @@
{
"comments": {
"lineComment": "",
"blockComment": ["<!--", "-->"]
"blockComment": [ "<!--", "-->" ]
},
"brackets": [
["<", ">"]
["<!--", "-->"],
["<", ">"],
["{", "}"],
["(", ")"]
],
"autoClosingPairs": [
["<", ">"],
["'", "'"],
["\"", "\""]
{ "open": "{", "close": "}"},
{ "open": "[", "close": "]"},
{ "open": "(", "close": ")" },
{ "open": "'", "close": "'" },
{ "open": "\"", "close": "\"" },
{ "open": "<!--", "close": "-->", "notIn": [ "comment", "string" ]},
{ "open": "<![CDATA[", "close": "]]>", "notIn": [ "comment", "string" ]}
],
"surroundingPairs": [
["<", ">"],
["'", "'"],
["\"", "\""]
]
// enhancedBrackets: [{
// tokenType: 'tag.tag-$1.xml',
// openTrigger: '>',
// open: /<(\w[\w\d]*)([^\/>]*(?!\/)>)[^<>]*$/i,
// closeComplete: '</$1>',
// closeTrigger: '>',
// close: /<\/(\w[\w\d]*)\s*>$/i
// }],
// autoClosingPairs: [['\'', '\''], ['"', '"'] ]
{ "open": "'", "close": "'" },
{ "open": "\"", "close": "\"" },
{ "open": "{", "close": "}"},
{ "open": "[", "close": "]"},
{ "open": "(", "close": ")" },
{ "open": "<", "close": ">" }
],
"folding": {
"markers": {
"start": "^\\s*<!--\\s*#region\\b.*-->",
"end": "^\\s*<!--\\s*#endregion\\b.*-->"
}
}
}