Skip to content

Commit

Permalink
chore: Upgrade typescript parser
Browse files Browse the repository at this point in the history
  • Loading branch information
bradzacher authored and zimme committed Jun 15, 2019
1 parent deb9d48 commit b73fef1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -18,6 +18,7 @@
],
"license": "MIT",
"dependencies": {
"@typescript-eslint/parser": "1.10.2",
"babel-runtime": "^6.26.0",
"common-tags": "^1.4.0",
"dlv": "^1.1.0",
Expand All @@ -29,7 +30,6 @@
"pretty-format": "^23.0.1",
"require-relative": "^0.8.7",
"typescript": "^2.5.1",
"typescript-eslint-parser": "^16.0.0",
"vue-eslint-parser": "^2.0.2"
},
"devDependencies": {
Expand Down
8 changes: 3 additions & 5 deletions src/index.js
Expand Up @@ -120,11 +120,9 @@ function format(options) {
}

if ([".ts", ".tsx"].includes(fileExtension)) {
// XXX: It seems babylon is getting a TypeScript plugin.
// Should that be used instead?
formattingOptions.eslint.parser = formattingOptions.eslint.parser || require.resolve(
"typescript-eslint-parser"
);
formattingOptions.eslint.parser =
formattingOptions.eslint.parser ||
require.resolve("@typescript-eslint/parser");
}

if ([".vue"].includes(fileExtension)) {
Expand Down

0 comments on commit b73fef1

Please sign in to comment.