Skip to content

Commit 5cae319

Browse files
committed
Jsx are available in expression context not in statement context
1 parent 1f019cc commit 5cae319

File tree

3 files changed

+2
-11
lines changed

3 files changed

+2
-11
lines changed

TypeScriptReact.YAML-tmLanguage

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@ uuid: 805375ec-d614-41f5-8993-5843fe63ea82
1010

1111
repository:
1212
# Additions:
13-
# statements and expression repository need to include jsx first followed by whaterver ts grammar says
14-
statements:
15-
patterns:
16-
- include: '#jsx'
17-
13+
# expression repository need to include jsx first followed by whaterver ts grammar says
1814
expression:
1915
patterns:
2016
- include: '#jsx'

TypeScriptReact.tmLanguage

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,6 @@
2525
<dict>
2626
<key>patterns</key>
2727
<array>
28-
<dict>
29-
<key>include</key>
30-
<string>#jsx</string>
31-
</dict>
3228
<dict>
3329
<key>include</key>
3430
<string>#string</string>

build/build.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,8 @@ function changeTsToTsxGrammar(grammar: any) {
4949
const updatesRepository = tsxUpdates.repository;
5050
for (let key in updatesRepository) {
5151
switch(key) {
52-
case "statements":
5352
case "expression":
54-
// Update statements/expression
53+
// Update expression
5554
repository[key].patterns.unshift(updatesRepository[key].patterns[0]);
5655
break;
5756
default:

0 commit comments

Comments
 (0)