-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathtsconfig.json
More file actions
63 lines (57 loc) · 3.51 KB
/
tsconfig.json
File metadata and controls
63 lines (57 loc) · 3.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
{
"compilerOptions": {
// Language and Environment
"target": "ES2022", // Node 18+ supports ES2022
"lib": ["ES2022"], // ES2022 standard library
"types": ["node"], // Explicit @types/* opt-in (TS 6 tightened auto-include)
// Module System (CommonJS by default, packages can override)
"module": "commonjs", // CommonJS for Node.js compatibility
"moduleResolution": "node", // Standard Node.js resolution
"esModuleInterop": true, // Interop between ES modules and CommonJS
"allowSyntheticDefaultImports": true, // Allow default imports from CommonJS
"resolveJsonModule": true, // Import JSON files
// Emit Configuration
"declaration": true, // Generate .d.ts files
"declarationMap": true, // Generate sourcemaps for declarations
"sourceMap": true, // Generate sourcemaps
"incremental": true, // Enable incremental compilation
"removeComments": false, // Keep comments in output
"preserveConstEnums": true, // Keep const enums
// Type Checking - Strict Mode
"strict": true, // Enable all strict type checking options
"noImplicitAny": true, // Error on implicit any
"strictNullChecks": true, // Strict null/undefined checks
"strictFunctionTypes": true, // Strict function type checking
"strictBindCallApply": true, // Strict bind/call/apply
"strictPropertyInitialization": true, // Strict property initialization
"noImplicitThis": true, // Error on implicit this
"useUnknownInCatchVariables": true, // Default catch variables to unknown
"alwaysStrict": true, // Emit "use strict" for each file
// Additional Checks
"noUnusedLocals": true, // Error on unused locals
"noUnusedParameters": true, // Error on unused parameters
"exactOptionalPropertyTypes": false, // Disabled - too restrictive for optional properties
"noImplicitReturns": true, // Error when not all paths return
"noFallthroughCasesInSwitch": true, // Error on fallthrough in switch
"noUncheckedIndexedAccess": false, // Don't add undefined to index signatures (too strict for existing code)
"noImplicitOverride": true, // Require override keyword
"noPropertyAccessFromIndexSignature": false, // Allow dot notation for index signatures
// Module Interop
"allowUnusedLabels": false, // Error on unused labels
"allowUnreachableCode": false, // Error on unreachable code
// Advanced Options
"skipLibCheck": true, // Skip type checking of declaration files
"forceConsistentCasingInFileNames": true, // Ensure consistent file name casing
"isolatedModules": true, // Ensure each file can be transpiled in isolation
"verbatimModuleSyntax": false, // Keep false for backward compatibility
"allowImportingTsExtensions": false // Disallow .ts extensions in imports
},
"exclude": [
"node_modules",
"**/node_modules",
"**/dist",
"**/examples",
"apps/frontend",
"apps/frontend/.next"
]
}