Skip to content

Commit 89d7056

Browse files
committed
Auto merge of #15154 - tetsuharuohzeki:tsconfig-strictest, r=lnicola
editor/code: Use `@tsconfig/strictest` to define type checking rules Motivation ----------- This change aims to make it easier to manage tsconfig by [``@tsconfig/strictest`](https://www.npmjs.com/package/@tsconfig/strictest)` and intend to leave to create "ideal" rules about TypeScript's type checking. Implementation --------------- This change removes some duplicated rules defined in ``@tsconfig/strictest`` and add disabing some strict rules that fails with the current codebase.
2 parents b2ddf14 + 0ddf8b6 commit 89d7056

File tree

3 files changed

+17
-6
lines changed

3 files changed

+17
-6
lines changed

editors/code/package-lock.json

+7
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

editors/code/package.json

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
"vscode-languageclient": "^8.1.0"
4949
},
5050
"devDependencies": {
51+
"@tsconfig/strictest": "^2.0.1",
5152
"@types/node": "~16.11.7",
5253
"@types/vscode": "~1.78.1",
5354
"@typescript-eslint/eslint-plugin": "^5.60.1",

editors/code/tsconfig.json

+9-6
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
11
{
2+
"extends": "@tsconfig/strictest/tsconfig.json",
23
"compilerOptions": {
4+
"esModuleInterop": false,
35
"module": "commonjs",
46
"target": "es2021",
57
"outDir": "out",
68
"lib": ["es2021"],
79
"sourceMap": true,
810
"rootDir": ".",
9-
"strict": true,
11+
"newLine": "LF",
12+
// These disables some enhancement type checking options
13+
// to update typescript version without any code change.
1014
"useUnknownInCatchVariables": false,
11-
"noUnusedLocals": true,
12-
"noUnusedParameters": true,
13-
"noImplicitReturns": true,
14-
"noFallthroughCasesInSwitch": true,
15-
"newLine": "LF"
15+
"exactOptionalPropertyTypes": false,
16+
"noImplicitOverride": false,
17+
"noPropertyAccessFromIndexSignature": false,
18+
"noUncheckedIndexedAccess": false
1619
},
1720
"exclude": ["node_modules", ".vscode-test"],
1821
"include": ["src", "tests"]

0 commit comments

Comments
 (0)