cb69a692e7
## Summary Remove the deprecated `baseUrl: "."` from [`tsconfig.base.json`](tsconfig.base.json). TypeScript 5.x flags it as deprecated; it stops functioning in TS 7.0. Since TS 5.0, `paths` keys are resolved relative to the tsconfig file where they are declared when `baseUrl` is absent — and the repo root is exactly what `baseUrl: "."` was pointing at. ## Why this is a no-op Our `paths` entries already start with `./libs/shared/.../src/index.ts` (relative to the repo root, which is `tsconfig.base.json`'s directory). With or without `baseUrl: "."`, the resolver lands on the same files. No other tsconfig in the workspace declares `baseUrl` (only `tsconfig.base.json` did), and the only path imports across the codebase are the workspace aliases (`shared-ui`, `shared-state`, `shared-tokens`, `shared-util`, `feature-auth`). `rootDir: "."` stays — it is independent of the deprecation and removing it would change `dist/` layout semantics across the workspace. Revisit only if a future TS version flags it. ## Verification `pnpm exec nx run-many -t lint test build --projects=portal-shell,portal-admin,shared-ui,shared-state,shared-tokens,shared-util` — green across 6 projects. The IDE deprecation warning is gone. --------- Co-authored-by: Julien Gautier <julien.gautier@apf.asso.fr> Reviewed-on: #101
34 lines
1.0 KiB
JSON
34 lines
1.0 KiB
JSON
{
|
|
"compilerOptions": {
|
|
"rootDir": ".",
|
|
"paths": {
|
|
"shared-tokens": ["./libs/shared/tokens/src/index.ts"],
|
|
"shared-util": ["./libs/shared/util/src/index.ts"],
|
|
"shared-ui": ["./libs/shared/ui/src/index.ts"],
|
|
"feature-auth": ["./libs/feature/auth/src/index.ts"],
|
|
"shared-state": ["./libs/shared/state/src/index.ts"]
|
|
},
|
|
"sourceMap": true,
|
|
"declaration": false,
|
|
"importHelpers": true,
|
|
"isolatedModules": true,
|
|
"lib": ["es2022", "dom"],
|
|
"module": "esnext",
|
|
"moduleResolution": "bundler",
|
|
"target": "es2022",
|
|
"experimentalDecorators": true,
|
|
"emitDecoratorMetadata": true,
|
|
"useDefineForClassFields": false,
|
|
"noFallthroughCasesInSwitch": true,
|
|
"noImplicitOverride": true,
|
|
"noImplicitReturns": true,
|
|
"noUnusedLocals": true,
|
|
"skipLibCheck": true,
|
|
"skipDefaultLibCheck": true,
|
|
"strict": true,
|
|
"noUncheckedIndexedAccess": true,
|
|
"exactOptionalPropertyTypes": true,
|
|
"noPropertyAccessFromIndexSignature": true
|
|
}
|
|
}
|