Skip to content

Commit

Permalink
fix: syntax, support tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
lili.21 committed Jan 17, 2024
1 parent 37742f6 commit cb7da4d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"git.ignoreLimitWarning": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
"source.fixAll.eslint": "explicit"
},
"editor.formatOnSave": false,
"[javascript]": {
Expand Down
3 changes: 2 additions & 1 deletion bin/transformer.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ async function getTransformerChoices(files) {
const result = await swc.parseFile(file, {
jsx: true,
tsx: true,
decorators: true
decorators: true,
syntax: 'typescript'
})
const importDeclaration = result.body.find(
(node) =>
Expand Down

0 comments on commit cb7da4d

Please sign in to comment.