mirror of
https://github.com/musistudio/claude-code-router.git
synced 2026-10-20 02:48:37 +00:00
TypeScript 6 reports it as an error:
Option 'baseUrl' is deprecated and will stop functioning in TypeScript 7.0.
Specify compilerOption '"ignoreDeprecations": "6.0"' to silence this error.
The repo pins typescript 5.9.3, so the current typecheck is quiet, but an
editor running a newer TypeScript flags it, and it becomes a hard failure
whenever the pin moves to 7.
In both configs baseUrl only anchors `paths`, and `paths` has not needed
it since TypeScript 4.4 — entries resolve relative to the tsconfig that
declares them. Every path here is already written relatively
("./packages/…", "./src/*"), so removing the line is the whole change.
Chose this over `"ignoreDeprecations": "6.0"`: that key silences the
message for one major version and has to be revisited, while this makes
the configs correct.
Nothing relies on baseUrl for bare-specifier resolution — there are no
`from "packages/…"` or `from "src/…"` imports under packages/*/src or
tests/e2e.
Verified with the repo's own typescript:
tsconfig.json 0 errors before, 0 after (234 files import via
@ccr/* or @/*, so a broken alias could not be silent)
tsconfig.node.json 1 error before, 1 after, byte-identical output —
a pre-existing TS18003 (its include is
"build/**/*.mjs" and allowJs is off), untouched here.
Re-checked both under TypeScript 6.0.3: the deprecation is gone and no new
diagnostic replaces it.
33 lines
924 B
JSON
33 lines
924 B
JSON
{
|
|
"compilerOptions": {
|
|
"target": "ESNext",
|
|
"useDefineForClassFields": true,
|
|
"module": "NodeNext",
|
|
"moduleResolution": "NodeNext",
|
|
"strict": true,
|
|
"jsx": "react-jsx",
|
|
"resolveJsonModule": true,
|
|
"isolatedModules": true,
|
|
"esModuleInterop": true,
|
|
"allowSyntheticDefaultImports": true,
|
|
"lib": ["ESNext", "DOM", "DOM.Iterable"],
|
|
"skipLibCheck": true,
|
|
"noEmit": true,
|
|
"noUnusedLocals": true,
|
|
"noUnusedParameters": true,
|
|
"paths": {
|
|
"@/*": ["./packages/ui/src/*"],
|
|
"@ccr/cli/*": ["./packages/cli/src/*"],
|
|
"@ccr/core/*": ["./packages/core/src/*"],
|
|
"@ccr/electron/*": ["./packages/electron/src/*"],
|
|
"@ccr/ui/*": ["./packages/ui/src/*"]
|
|
}
|
|
},
|
|
"include": [
|
|
"packages/*/src/**/*.ts",
|
|
"packages/*/src/**/*.d.ts",
|
|
"packages/*/src/**/*.tsx",
|
|
"tests/e2e/**/*.ts"
|
|
],
|
|
"references": [{ "path": "./tsconfig.node.json" }]
|
|
}
|