Skip to content

Commit

Permalink
[JS] Fix "from" inside import block
Browse files Browse the repository at this point in the history
  • Loading branch information
borela committed Aug 26, 2018
1 parent 1c42cb1 commit 97bfdc2
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion syntaxes/fjsx15/import.sublime-syntax
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ contexts:
arguments:
- include: Packages/Naomi/syntaxes/fjsx15/expression.sublime-syntax

block-optional-target:
- include: comment-no-pop
- match: (?=(?>[,}]))
pop: true
- include: shared-optional-target

close-block:
- match: \}
scope: punctuation.section.block.end.js.fjsx15
Expand Down Expand Up @@ -98,6 +104,9 @@ contexts:
- include: comment-no-pop
- match: (?=(?>[,}]|from))
pop: true
- include: shared-optional-target

shared-optional-target:
# Type.
- include: Packages/Naomi/syntaxes/flow1/type-import.sublime-syntax
# Aliased All.
Expand All @@ -114,7 +123,7 @@ contexts:
set: [
close-block,
delimiter,
optional-target
block-optional-target
]
# Aliased.
- match: (?xi){{commonIdentifier}}(?=\s+as)
Expand Down

0 comments on commit 97bfdc2

Please sign in to comment.