1 | Prism.languages.editorconfig = {
|
2 | // https://editorconfig-specification.readthedocs.io/en/latest/
|
3 | 'comment': /[;#].*/,
|
4 | 'section': {
|
5 | pattern: /(^[ \t]*)\[.+]/m,
|
6 | lookbehind: true,
|
7 | alias: 'keyword',
|
8 | inside: {
|
9 | 'regex': /\\\\[\[\]{},!?.*]/, // Escape special characters with '\\'
|
10 | 'operator': /[!?]|\.\.|\*{1,2}/,
|
11 | 'punctuation': /[\[\]{},]/
|
12 | }
|
13 | },
|
14 | 'property': {
|
15 | pattern: /(^[ \t]*)[^\s=]+(?=[ \t]*=)/m,
|
16 | lookbehind: true
|
17 | },
|
18 | 'value': {
|
19 | pattern: /=.*/,
|
20 | alias: 'string',
|
21 | inside: {
|
22 | 'punctuation': /^=/
|
23 | }
|
24 | }
|
25 | };
|