mirror of
https://github.com/hanzoai/viem.git
synced 2026-10-30 19:36:39 +00:00
44 lines
1.7 KiB
JSON
44 lines
1.7 KiB
JSON
{
|
|
// Shared compiler options extended by the root and project tsconfigs.
|
|
"include": [],
|
|
"exclude": ["site/pages.gen.ts"],
|
|
"compilerOptions": {
|
|
// Incremental builds
|
|
// NOTE: Enabling incremental builds speeds up `tsc`. Keep in mind though that it does not reliably bust the cache when the `tsconfig.json` file changes.
|
|
"incremental": true,
|
|
|
|
// Type checking
|
|
"strict": true,
|
|
"useDefineForClassFields": true, // Not enabled by default in `strict` mode unless we bump `target` to ES2022.
|
|
"noFallthroughCasesInSwitch": true, // Not enabled by default in `strict` mode.
|
|
"noImplicitReturns": true, // Not enabled by default in `strict` mode.
|
|
"useUnknownInCatchVariables": true, // Enabled by default in `strict` mode.
|
|
"noImplicitOverride": true, // Not enabled by default in `strict` mode.
|
|
"noUnusedLocals": true, // Not enabled by default in `strict` mode.
|
|
"noUnusedParameters": true, // Not enabled by default in `strict` mode.
|
|
"exactOptionalPropertyTypes": true,
|
|
"noUncheckedIndexedAccess": true,
|
|
|
|
// JavaScript support
|
|
"allowJs": false,
|
|
"checkJs": false,
|
|
|
|
// Interop constraints
|
|
"forceConsistentCasingInFileNames": true,
|
|
"verbatimModuleSyntax": true,
|
|
|
|
// Language and environment
|
|
"moduleResolution": "NodeNext",
|
|
"module": "NodeNext",
|
|
"target": "ES2021",
|
|
"types": ["node"],
|
|
"lib": [
|
|
"ES2022", // By using ES2022 we get access to the `.cause` property on `Error` instances.
|
|
"DOM" // We are adding `DOM` here to get the `fetch`, etc. types. This should be removed once these types are available via DefinitelyTyped.
|
|
],
|
|
|
|
// Skip type checking for node modules
|
|
"skipLibCheck": true
|
|
}
|
|
}
|