Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Dec 25, 2025. It is now read-only.

Commit 8b88a68

Browse files
author
Tobermory
authored
Merge pull request #43 from JeremyMoeglich/master
Added support for .svelte files
2 parents 2ec2e73 + e217611 commit 8b88a68

File tree

4 files changed

+201
-156
lines changed

4 files changed

+201
-156
lines changed

package.json

Lines changed: 167 additions & 156 deletions
Original file line numberDiff line numberDiff line change
@@ -1,157 +1,168 @@
11
{
2-
"name": "es6-string-html",
3-
"displayName": "es6-string-html",
4-
"description": "Syntax highlighting in es6 multiline strings",
5-
"version": "2.11.0",
6-
"publisher": "Tobermory",
7-
"icon": "docs/logo.png",
8-
"engines": {
9-
"vscode": "^1.19.0"
10-
},
11-
"galleryBanner": {
12-
"color": "#dedede",
13-
"theme": "light"
14-
},
15-
"repository": {
16-
"url": "https://github.com/mydesireiscoma/es6-string-html"
17-
},
18-
"bugs": {
19-
"url": "https://github.com/mydesireiscoma/es6-string-html/issues"
20-
},
21-
"main": "./scripts/main",
22-
"categories": [
23-
"Programming Languages"
24-
],
25-
"keywords": [
26-
"javascript",
27-
"es6",
28-
"es6-string-html",
29-
"html",
30-
"sql",
31-
"xml",
32-
"svg"
33-
],
34-
"activationEvents": [
35-
"onCommand:es6stringhtml.insertComment",
36-
"onCommand:es6stringhtml.insertTemplate"
37-
],
38-
"contributes": {
39-
"commands": [
40-
{
41-
"command": "es6stringhtml.insertComment",
42-
"title": "Insert es6-string-html comment",
43-
"category": "HTML"
44-
},
45-
{
46-
"command": "es6stringhtml.insertTemplate",
47-
"title": "Insert es6-string-html template",
48-
"category": "HTML"
49-
}
50-
],
51-
"grammars": [
52-
{
53-
"injectTo": [
54-
"source.html",
55-
"source.js",
56-
"source.js.jsx",
57-
"source.jsx",
58-
"source.ts",
59-
"source.tsx",
60-
"source.vue",
61-
"source.sql",
62-
"source.css",
63-
"text.html"
64-
],
65-
"scopeName": "inline.es6-css",
66-
"path": "./syntaxes/es6-inline-css.json",
67-
"embeddedLanguages": {
68-
"meta.embedded.block.html": "html"
69-
}
70-
},
71-
{
72-
"injectTo": [
73-
"source.html",
74-
"source.js",
75-
"source.js.jsx",
76-
"source.jsx",
77-
"source.ts",
78-
"source.tsx",
79-
"source.vue",
80-
"source.sql",
81-
"text.html"
82-
],
83-
"scopeName": "inline.es6-glsl",
84-
"path": "./syntaxes/es6-inline-glsl.json",
85-
"embeddedLanguages": {
86-
"meta.embedded.glsl": "glsl"
87-
}
88-
},
89-
{
90-
"injectTo": [
91-
"source.html",
92-
"source.js",
93-
"source.js.jsx",
94-
"source.jsx",
95-
"source.ts",
96-
"source.tsx",
97-
"source.vue",
98-
"source.sql",
99-
"text.html"
100-
],
101-
"scopeName": "inline.es6-xml",
102-
"path": "./syntaxes/es6-inline-xml.json",
103-
"embeddedLanguages": {
104-
"meta.embedded.xml": "xml"
105-
}
106-
},
107-
{
108-
"injectTo": [
109-
"source.html",
110-
"source.js",
111-
"source.js.jsx",
112-
"source.jsx",
113-
"source.ts",
114-
"source.tsx",
115-
"source.vue",
116-
"source.sql",
117-
"text.html"
118-
],
119-
"scopeName": "inline.es6-js-injection",
120-
"path": "./syntaxes/es6-js-injection.json"
121-
},
122-
{
123-
"injectTo": [
124-
"source.html",
125-
"source.js",
126-
"source.js.jsx",
127-
"source.jsx",
128-
"source.ts",
129-
"source.tsx",
130-
"source.vue",
131-
"source.sql",
132-
"text.html"
133-
],
134-
"scopeName": "inline.es6-html",
135-
"path": "./syntaxes/es6-inline-html.json"
136-
},
137-
{
138-
"injectTo": [
139-
"source.html",
140-
"source.js",
141-
"source.js.jsx",
142-
"source.jsx",
143-
"source.ts",
144-
"source.tsx",
145-
"source.vue",
146-
"source.sql",
147-
"text.html"
148-
],
149-
"scopeName": "inline.es6-sql",
150-
"path": "./syntaxes/es6-inline-sql.json",
151-
"embeddedLanguages": {
152-
"meta.embedded.block.sql": "sql"
153-
}
154-
}
155-
]
156-
}
157-
}
2+
"name": "es6-string-html",
3+
"displayName": "es6-string-html",
4+
"description": "Syntax highlighting in es6 multiline strings",
5+
"version": "2.11.0",
6+
"publisher": "Tobermory",
7+
"icon": "docs/logo.png",
8+
"engines": {
9+
"vscode": "^1.19.0"
10+
},
11+
"galleryBanner": {
12+
"color": "#dedede",
13+
"theme": "light"
14+
},
15+
"repository": {
16+
"url": "https://github.com/mydesireiscoma/es6-string-html"
17+
},
18+
"bugs": {
19+
"url": "https://github.com/mydesireiscoma/es6-string-html/issues"
20+
},
21+
"main": "./scripts/main",
22+
"categories": [
23+
"Programming Languages"
24+
],
25+
"keywords": [
26+
"javascript",
27+
"es6",
28+
"es6-string-html",
29+
"html",
30+
"sql",
31+
"xml",
32+
"svg"
33+
],
34+
"activationEvents": [
35+
"onCommand:es6stringhtml.insertComment",
36+
"onCommand:es6stringhtml.insertTemplate"
37+
],
38+
"contributes": {
39+
"commands": [
40+
{
41+
"command": "es6stringhtml.insertComment",
42+
"title": "Insert es6-string-html comment",
43+
"category": "HTML"
44+
},
45+
{
46+
"command": "es6stringhtml.insertTemplate",
47+
"title": "Insert es6-string-html template",
48+
"category": "HTML"
49+
}
50+
],
51+
"grammars": [
52+
{
53+
"injectTo": [
54+
"source.html",
55+
"source.js",
56+
"source.js.jsx",
57+
"source.jsx",
58+
"source.ts",
59+
"source.tsx",
60+
"source.vue",
61+
"source.svelte",
62+
"source.sql",
63+
"source.css",
64+
"text.html"
65+
],
66+
"scopeName": "inline.es6-css",
67+
"path": "./syntaxes/es6-inline-css.json",
68+
"embeddedLanguages": {
69+
"meta.embedded.block.html": "html"
70+
}
71+
},
72+
{
73+
"injectTo": [
74+
"source.html",
75+
"source.js",
76+
"source.js.jsx",
77+
"source.jsx",
78+
"source.ts",
79+
"source.tsx",
80+
"source.vue",
81+
"source.svelte",
82+
"source.sql",
83+
"text.html"
84+
],
85+
"scopeName": "inline.es6-glsl",
86+
"path": "./syntaxes/es6-inline-glsl.json",
87+
"embeddedLanguages": {
88+
"meta.embedded.glsl": "glsl"
89+
}
90+
},
91+
{
92+
"injectTo": [
93+
"source.html",
94+
"source.js",
95+
"source.js.jsx",
96+
"source.jsx",
97+
"source.ts",
98+
"source.tsx",
99+
"source.vue",
100+
"source.svelte",
101+
"source.sql",
102+
"text.html"
103+
],
104+
"scopeName": "inline.es6-xml",
105+
"path": "./syntaxes/es6-inline-xml.json",
106+
"embeddedLanguages": {
107+
"meta.embedded.xml": "xml"
108+
}
109+
},
110+
{
111+
"injectTo": [
112+
"source.html",
113+
"source.js",
114+
"source.js.jsx",
115+
"source.jsx",
116+
"source.ts",
117+
"source.tsx",
118+
"source.vue",
119+
"source.svelte",
120+
"source.sql",
121+
"text.html"
122+
],
123+
"scopeName": "inline.es6-js-injection",
124+
"path": "./syntaxes/es6-js-injection.json"
125+
},
126+
{
127+
"injectTo": [
128+
"source.html",
129+
"source.js",
130+
"source.js.jsx",
131+
"source.jsx",
132+
"source.ts",
133+
"source.tsx",
134+
"source.vue",
135+
"source.svelte",
136+
"source.sql",
137+
"text.html"
138+
],
139+
"scopeName": "inline.es6-html",
140+
"path": "./syntaxes/es6-inline-html.json"
141+
},
142+
{
143+
"injectTo": [
144+
"source.html",
145+
"source.js",
146+
"source.js.jsx",
147+
"source.jsx",
148+
"source.ts",
149+
"source.tsx",
150+
"source.vue",
151+
"source.svelte",
152+
"source.sql",
153+
"text.html"
154+
],
155+
"scopeName": "inline.es6-sql",
156+
"path": "./syntaxes/es6-inline-sql.json",
157+
"embeddedLanguages": {
158+
"meta.embedded.block.sql": "sql"
159+
}
160+
}
161+
]
162+
},
163+
"__metadata": {
164+
"id": "db50f65a-6c7c-4134-8e8d-e6b8a9c738da",
165+
"publisherDisplayName": "Tobermory",
166+
"publisherId": "ea206736-c554-4aad-bb7f-813836f42f78"
167+
}
168+
}
File renamed without changes.

tests/test.svelte

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<script>
2+
let tests = [
3+
/*html*/`<div>OK</div>`,
4+
/* INLINE-HTML */ `<div>Test</div>$`,
5+
/*css*/`
6+
.className {
7+
color: red;
8+
}
9+
`,
10+
// html
11+
`
12+
<div>Test</div>
13+
`,
14+
/* html */
15+
`
16+
<div>Test</div>
17+
`,
18+
/*sql*/
19+
`
20+
SELECT * FROM test
21+
WHERE ProductName NOT BETWEEN 'Carnarvon Tigers' AND 'Mozzarella di Giovanni'
22+
ORDER BY ProductName;
23+
`,
24+
/*XML*/
25+
`
26+
<?xml version="1.0" encoding="UTF-8"?>
27+
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
28+
<url>
29+
<loc>http://www.example.com/</loc>
30+
</url>
31+
</urlset>
32+
`
33+
]
34+
</script>
File renamed without changes.

0 commit comments

Comments
 (0)