Skip to content

Commit

Permalink
Merge pull request #604 from mishoo/export-as-string
Browse files Browse the repository at this point in the history
fix parsing export { foo as "bar" }
  • Loading branch information
dgutov authored Sep 8, 2024
2 parents 9b90d31 + a8b1a5c commit 62d6cb1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion js2-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -8984,7 +8984,8 @@ consumes no tokens."
(let ((name
(or
(and (js2-match-token js2-DEFAULT) "default")
(and (js2-match-token js2-NAME) (js2-current-token-string)))))
(and (js2-match-token js2-NAME) (js2-current-token-string))
(and (js2-match-token js2-STRING) (js2-current-token-string)))))
(if name
(let ((node (make-js2-export-binding-node
:pos beg
Expand Down

0 comments on commit 62d6cb1

Please sign in to comment.