mirror of
https://github.com/hanzoai/analytics.git
synced 2026-10-30 15:05:29 +00:00
TypeScript 7 does not auto-include every installed @types package the way
TS 5.x does, so the jest globals went missing and every test file failed
with TS2304/TS2593 ("Cannot find name 'expect' / 'describe'") — 92 errors
for a type package that was installed all along.
Declaring `types: ["node", "jest"]` restores them:
tsc 7 357 -> 256 errors (test globals 92 -> 0)
tsc 5.9 254 -> 254 (unchanged — the list matches what it
already inferred)
With the gap closed the compilers agree within 2, so typescript moves to
^7.0.2. The build does not emit through tsc, so the artifact is unaffected.
Co-authored-by: Hanzo Dev <[email protected]>
40 lines
964 B
JSON
40 lines
964 B
JSON
{
|
|
"compilerOptions": {
|
|
"target": "es2022",
|
|
"module": "esnext",
|
|
"moduleResolution": "bundler",
|
|
"resolveJsonModule": true,
|
|
"isolatedModules": true,
|
|
"lib": ["dom", "dom.iterable", "esnext"],
|
|
"skipLibCheck": true,
|
|
"esModuleInterop": true,
|
|
"noImplicitAny": false,
|
|
"preserveConstEnums": true,
|
|
"removeComments": true,
|
|
"sourceMap": true,
|
|
"allowSyntheticDefaultImports": true,
|
|
"forceConsistentCasingInFileNames": true,
|
|
"allowJs": true,
|
|
"strict": true,
|
|
"strictNullChecks": false,
|
|
"noEmit": true,
|
|
"jsx": "preserve",
|
|
"incremental": false,
|
|
"outDir": "./build",
|
|
"paths": {
|
|
"@/*": ["./src/*"]
|
|
},
|
|
"plugins": [
|
|
{
|
|
"name": "next"
|
|
}
|
|
],
|
|
"types": [
|
|
"node",
|
|
"jest"
|
|
]
|
|
},
|
|
"include": ["**/*.ts", "**/*.tsx", "**/*.js", "**/*.jsx", "next-env.d.ts", ".next/types/**/*.ts"],
|
|
"exclude": ["node_modules", "./cypress.config.ts", "cypress"]
|
|
}
|