Skip to content

Commit 14ce715

Browse files
committed
build(tsconfig.ts): modernize and impprove compilerOptions
1 parent ef2caec commit 14ce715

File tree

2 files changed

+35
-9
lines changed

2 files changed

+35
-9
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
/lib/
22
/node_modules/
3+
tsconfig.tsbuildinfo

tsconfig.json

Lines changed: 34 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,53 @@
11
{
22
"compilerOptions": {
33
/* Type checking */
4+
// "exactOptionalPropertyTypes": true,
5+
"forceConsistentCasingInFileNames": true,
6+
"noFallthroughCasesInSwitch": true,
7+
"noImplicitOverride": true,
8+
"noImplicitReturns": true,
9+
// "noUncheckedIndexedAccess": true,
10+
"noPropertyAccessFromIndexSignature": true,
11+
"noUnusedLocals": true,
12+
"noUnusedParameters": true,
413
"strict": true,
514

615
/* Modules */
7-
"module": "esnext",
8-
"moduleResolution": "node",
9-
"rootDir": "./src",
16+
"module": "NodeNext",
17+
"moduleResolution": "NodeNext",
18+
"noUncheckedSideEffectImports": true,
19+
"types": [],
20+
"rootDir": "src",
1021

1122
/* Language and Environment */
12-
"target": "es6",
23+
"lib": ["ES2022", "DOM"],
24+
"moduleDetection": "force",
25+
"target": "ES2022",
26+
27+
/* Projects */
28+
"incremental": true,
29+
30+
/* Output Formatting */
31+
"noErrorTruncation": true,
1332

1433
/* Emit */
1534
"declaration": true,
1635
"declarationMap": true,
1736
"importHelpers": true,
37+
"inlineSources": true,
38+
"outDir": "lib",
1839
"sourceMap": true,
19-
"outDir": "./lib",
2040

2141
/* Interop Constraints */
22-
"esModuleInterop": true
42+
// "erasableSyntaxOnly": true,
43+
"esModuleInterop": true,
44+
"isolatedDeclarations": true,
45+
"isolatedModules": true,
46+
"verbatimModuleSyntax": true,
47+
48+
/* Completeness */
49+
"skipLibCheck": true
2350
},
24-
"exclude": [
25-
"src/**/*.test.ts",
26-
],
51+
"exclude": ["src/**/*.test.ts"],
2752
"include": ["./src"]
2853
}

0 commit comments

Comments
 (0)