Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,10 @@ TypeScript language service plugin to check ESLint errors.
### Requirements (peer dependencies)

- `typescript`
- `@typescript-eslint/parser` >= 3.0.0
- `@typescript-eslint/typescript-estree` >= 3.0.0
- `@typescript-eslint/parser` >= 3.5.0
- `@typescript-eslint/typescript-estree` >= 3.5.0
- `eslint`

**If your @typescript-eslint tool's version is < 3.0.0, install`typescript-eslint-language-service@2.x.x`.**

### Install

```sh
Expand Down Expand Up @@ -68,6 +66,11 @@ By default, this plugins watches only `.eslintrc.*` files that exist in your pro

- Set `TS_ESLINT_SERVICE_DISABLED` env parameter and restart your IDE to turn this plugin off.

### If you use older version of `@typescript-eslint` packages

- **If your @typescript-eslint tool's version is <= 3.4.0, install `typescript-eslint-language-service@3.0.x`.**
- **If your @typescript-eslint tool's version is <= 2.x.x, install `typescript-eslint-language-service@2.x.x`.**

## LICENSE

MIT
2 changes: 1 addition & 1 deletion e2e/projects/other-parser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
"@babel/core": "^7.7.4",
"babel-eslint": "^10.0.3",
"eslint": "^7.0.0",
"typescript": "^3.9.0"
"typescript": "4.0.1-rc"
}
}
4 changes: 2 additions & 2 deletions e2e/projects/simple/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"test": "echo \"Error: no test specified\" && exit 1"
},
"devDependencies": {
"@typescript-eslint/parser": "^3.0.0",
"@typescript-eslint/parser": "~3.9.0",
"eslint": "^7.0.0",
"typescript": "^3.9.0"
"typescript": "4.0.1-rc"
}
}
6 changes: 3 additions & 3 deletions e2e/projects/ts-eslint-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
"test": "echo \"Error: no test specified\" && exit 1"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "~3.4.0",
"@typescript-eslint/parser": "~3.4.0",
"@typescript-eslint/eslint-plugin": "~3.9.0",
"@typescript-eslint/parser": "~3.9.0",
"eslint": "^7.0.0",
"typescript": "^3.9.0"
"typescript": "4.0.1-rc"
}
}
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"url": "https://github.com/Quramy/typescript-eslint-language-service/issues"
},
"pperDependencies": {
"@typescript-eslint/parser": ">= 3.0.2 <= 3.4.x",
"@typescript-eslint/typescript-estree": ">= 3.0.2 <= 3.4.x",
"@typescript-eslint/parser": ">= 3.5.0",
"@typescript-eslint/typescript-estree": ">= 3.5.0",
"eslint": ">= 6.7.0 <= 6.8.x || >= 7.0.0",
"typescript": "^3.0.0"
},
Expand All @@ -38,9 +38,9 @@
"@types/eslint": "^6.1.3",
"@types/jest": "^25.1.4",
"@types/node": "^14.0.6",
"@typescript-eslint/eslint-plugin": "~3.4.0",
"@typescript-eslint/parser": "~3.8.0",
"@typescript-eslint/typescript-estree": "~3.4.0",
"@typescript-eslint/eslint-plugin": "~3.9.0",
"@typescript-eslint/parser": "~3.9.0",
"@typescript-eslint/typescript-estree": "~3.9.0",
"eslint": "^7.0.0",
"eslint-config-prettier": "^6.11.0",
"fretted-strings": "^1.0.0",
Expand All @@ -50,7 +50,7 @@
"pretty-quick": "^2.0.1",
"rimraf": "^3.0.0",
"ts-jest": "^26.0.0",
"typescript": "~3.9.0"
"typescript": "4.0.1-rc"
},
"husky": {
"hooks": {
Expand Down
2 changes: 1 addition & 1 deletion src/ast-converter.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import ts from "typescript";
import { AstConverter } from "./ast-converter";
import { SourceCode } from "eslint";
import { visitorKeys as tsEslintVisitorKeys } from "@typescript-eslint/typescript-estree/dist/visitor-keys";
import { visitorKeys as tsEslintVisitorKeys } from "@typescript-eslint/visitor-keys";

function createProgram() {
return ts.createProgram({
Expand Down
2 changes: 1 addition & 1 deletion src/ast-converter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { SourceCode, AST, Scope } from "eslint";
import { ParserOptions } from "@typescript-eslint/parser";
import { analyzeScope } from "@typescript-eslint/parser/dist/analyze-scope";
import { Extra } from "@typescript-eslint/typescript-estree/dist/parser-options";
import { visitorKeys } from "@typescript-eslint/typescript-estree/dist/visitor-keys";
import { visitorKeys } from "@typescript-eslint/visitor-keys";
import { ParseAndGenerateServicesResult, TSESTreeOptions } from "@typescript-eslint/typescript-estree";
import * as TsEstree from "@typescript-eslint/typescript-estree/dist/ast-converter";

Expand Down
2 changes: 1 addition & 1 deletion src/eslint-config-provider.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class FileUpdater {
fs.writeFileSync(this.path, this.originalContent, "utf8");
delete this.originalContent;
}
delete this.path;
delete (this as any).path;
this.callbackList = [];
}

Expand Down
95 changes: 36 additions & 59 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -609,86 +609,63 @@
dependencies:
"@types/yargs-parser" "*"

"@typescript-eslint/eslint-plugin@~3.4.0":
version "3.4.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-3.4.0.tgz#8378062e6be8a1d049259bdbcf27ce5dfbeee62b"
integrity sha512-wfkpiqaEVhZIuQRmudDszc01jC/YR7gMSxa6ulhggAe/Hs0KVIuo9wzvFiDbG3JD5pRFQoqnf4m7REDsUvBnMQ==
"@typescript-eslint/eslint-plugin@~3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-3.9.0.tgz#0fe529b33d63c9a94f7503ca2bb12c84b9477ff3"
integrity sha512-UD6b4p0/hSe1xdTvRCENSx7iQ+KR6ourlZFfYuPC7FlXEzdHuLPrEmuxZ23b2zW96KJX9Z3w05GE/wNOiEzrVg==
dependencies:
"@typescript-eslint/experimental-utils" "3.4.0"
"@typescript-eslint/experimental-utils" "3.9.0"
debug "^4.1.1"
functional-red-black-tree "^1.0.1"
regexpp "^3.0.0"
semver "^7.3.2"
tsutils "^3.17.1"

"@typescript-eslint/experimental-utils@3.4.0":
version "3.4.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-3.4.0.tgz#8a44dfc6fb7f1d071937b390fe27608ebda122b8"
integrity sha512-rHPOjL43lOH1Opte4+dhC0a/+ks+8gOBwxXnyrZ/K4OTAChpSjP76fbI8Cglj7V5GouwVAGaK+xVwzqTyE/TPw==
"@typescript-eslint/experimental-utils@3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-3.9.0.tgz#3171d8ddba0bf02a8c2034188593630914fcf5ee"
integrity sha512-/vSHUDYizSOhrOJdjYxPNGfb4a3ibO8zd4nUKo/QBFOmxosT3cVUV7KIg8Dwi6TXlr667G7YPqFK9+VSZOorNA==
dependencies:
"@types/json-schema" "^7.0.3"
"@typescript-eslint/typescript-estree" "3.4.0"
"@typescript-eslint/types" "3.9.0"
"@typescript-eslint/typescript-estree" "3.9.0"
eslint-scope "^5.0.0"
eslint-utils "^2.0.0"

"@typescript-eslint/experimental-utils@3.8.0":
version "3.8.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-3.8.0.tgz#ac1f7c88322dcfb7635ece6f0441516dd951099a"
integrity sha512-o8T1blo1lAJE0QDsW7nSyvZHbiDzQDjINJKyB44Z3sSL39qBy5L10ScI/XwDtaiunoyKGLiY9bzRk4YjsUZl8w==
dependencies:
"@types/json-schema" "^7.0.3"
"@typescript-eslint/types" "3.8.0"
"@typescript-eslint/typescript-estree" "3.8.0"
eslint-scope "^5.0.0"
eslint-utils "^2.0.0"

"@typescript-eslint/parser@~3.8.0":
version "3.8.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-3.8.0.tgz#8e1dcd404299bf79492409c81c415fa95a7c622b"
integrity sha512-u5vjOBaCsnMVQOvkKCXAmmOhyyMmFFf5dbkM3TIbg3MZ2pyv5peE4gj81UAbTHwTOXEwf7eCQTUMKrDl/+qGnA==
"@typescript-eslint/parser@~3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-3.9.0.tgz#344978a265d9a5c7c8f13e62c78172a4374dabea"
integrity sha512-rDHOKb6uW2jZkHQniUQVZkixQrfsZGUCNWWbKWep4A5hGhN5dLHMUCNAWnC4tXRlHedXkTDptIpxs6e4Pz8UfA==
dependencies:
"@types/eslint-visitor-keys" "^1.0.0"
"@typescript-eslint/experimental-utils" "3.8.0"
"@typescript-eslint/types" "3.8.0"
"@typescript-eslint/typescript-estree" "3.8.0"
"@typescript-eslint/experimental-utils" "3.9.0"
"@typescript-eslint/types" "3.9.0"
"@typescript-eslint/typescript-estree" "3.9.0"
eslint-visitor-keys "^1.1.0"

"@typescript-eslint/types@3.8.0":
version "3.8.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-3.8.0.tgz#58581dd863f86e0cd23353d94362bb90b4bea796"
integrity sha512-8kROmEQkv6ss9kdQ44vCN1dTrgu4Qxrd2kXr10kz2NP5T8/7JnEfYNxCpPkArbLIhhkGLZV3aVMplH1RXQRF7Q==

"@typescript-eslint/typescript-estree@3.4.0", "@typescript-eslint/typescript-estree@~3.4.0":
version "3.4.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-3.4.0.tgz#6a787eb70b48969e4cd1ea67b057083f96dfee29"
integrity sha512-zKwLiybtt4uJb4mkG5q2t6+W7BuYx2IISiDNV+IY68VfoGwErDx/RfVI7SWL4gnZ2t1A1ytQQwZ+YOJbHHJ2rw==
dependencies:
debug "^4.1.1"
eslint-visitor-keys "^1.1.0"
glob "^7.1.6"
is-glob "^4.0.1"
lodash "^4.17.15"
semver "^7.3.2"
tsutils "^3.17.1"
"@typescript-eslint/types@3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-3.9.0.tgz#be9d0aa451e1bf3ce99f2e6920659e5b2e6bfe18"
integrity sha512-rb6LDr+dk9RVVXO/NJE8dT1pGlso3voNdEIN8ugm4CWM5w5GimbThCMiMl4da1t5u3YwPWEwOnKAULCZgBtBHg==

"@typescript-eslint/typescript-estree@3.8.0":
version "3.8.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-3.8.0.tgz#0606d19f629f813dbdd5a34c7a1e895d6191cac6"
integrity sha512-MTv9nPDhlKfclwnplRNDL44mP2SY96YmPGxmMbMy6x12I+pERcxpIUht7DXZaj4mOKKtet53wYYXU0ABaiXrLw==
"@typescript-eslint/typescript-estree@3.9.0", "@typescript-eslint/typescript-estree@~3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-3.9.0.tgz#c6abbb50fa0d715cab46fef67ca6378bf2eaca13"
integrity sha512-N+158NKgN4rOmWVfvKOMoMFV5n8XxAliaKkArm/sOypzQ0bUL8MSnOEBW3VFIeffb/K5ce/cAV0yYhR7U4ALAA==
dependencies:
"@typescript-eslint/types" "3.8.0"
"@typescript-eslint/visitor-keys" "3.8.0"
"@typescript-eslint/types" "3.9.0"
"@typescript-eslint/visitor-keys" "3.9.0"
debug "^4.1.1"
glob "^7.1.6"
is-glob "^4.0.1"
lodash "^4.17.15"
semver "^7.3.2"
tsutils "^3.17.1"

"@typescript-eslint/visitor-keys@3.8.0":
version "3.8.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-3.8.0.tgz#ad35110249fb3fc30a36bfcbfeea93e710cfaab1"
integrity sha512-gfqQWyVPpT9NpLREXNR820AYwgz+Kr1GuF3nf1wxpHD6hdxI62tq03ToomFnDxY0m3pUB39IF7sil7D5TQexLA==
"@typescript-eslint/visitor-keys@3.9.0":
version "3.9.0"
resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-3.9.0.tgz#44de8e1b1df67adaf3b94d6b60b80f8faebc8dd3"
integrity sha512-O1qeoGqDbu0EZUC/MZ6F1WHTIzcBVhGqDj3LhTnj65WUA548RXVxUHbYhAW9bZWfb2rnX9QsbbP5nmeJ5Z4+ng==
dependencies:
eslint-visitor-keys "^1.1.0"

Expand Down Expand Up @@ -4120,10 +4097,10 @@ typedarray-to-buffer@^3.1.5:
dependencies:
is-typedarray "^1.0.0"

typescript@~3.9.0:
version "3.9.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.9.3.tgz#d3ac8883a97c26139e42df5e93eeece33d610b8a"
integrity sha512-D/wqnB2xzNFIcoBG9FG8cXRDjiqSTbG2wd8DMZeQyJlP1vfTkIxH4GKveWaEBYySKIg+USu+E+EDIR47SqnaMQ==
typescript@4.0.1-rc:
version "4.0.1-rc"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.0.1-rc.tgz#8adc78223eae56fe71d906a5fa90c3543b07a677"
integrity sha512-TCkspT3dSKOykbzS3/WSK7pqU2h1d/lEO6i45Afm5Y3XNAEAo8YXTG3kHOQk/wFq/5uPyO1+X8rb/Q+g7UsxJw==

union-value@^1.0.0:
version "1.0.1"
Expand Down