Skip to content

Migrate deprecated tsconfig options before TypeScript 7 (target, moduleResolution, baseUrl) #1706

Description

@yoganandaness

Context

As part of the TypeScript 6 upgrade (frontend), three compilerOptions in apps/frontend/tsconfig.json are now deprecated and will be removed in TypeScript 7. To keep TS 6 compiling, we currently suppress the deprecation errors with:

"ignoreDeprecations": "6.0"

This is a temporary shim. Before upgrading to TS 7, these options must be actually migrated and the ignoreDeprecations line removed.

Options to migrate

Current Target replacement Notes / risk
"target": "es5" "es2020" (or higher) Changes emitted JS (no more down-leveling). Vite controls the real build target, so mostly affects type-checking. Confirm browser-support matrix.
"moduleResolution": "node" "bundler" Matches our Vite setup. May surface import-path issues (exports fields, extensions).
"baseUrl": "src" "paths" Highest risk. paths only affects the type-checker; Vite resolves separately, so we also need resolve.alias (or vite-tsconfig-paths) to match, or runtime imports break.

Acceptance criteria

  • Replace target: es5 with es2020+
  • Replace moduleResolution: node with bundler
  • Replace baseUrl: src with explicit paths (+ matching Vite alias config)
  • Remove "ignoreDeprecations": "6.0" from apps/frontend/tsconfig.json
  • tsc --noEmit passes with no deprecation errors
  • Production build succeeds and a browser smoke test passes

Suggested approach

Do this as its own PR (cut from develop), separate from the TS 6 upgrade branch. Migrate one option at a time, verifying tsc --noEmit + a real build after each.

Reference: // Remove once those move to es2020 / bundler / paths comment in apps/frontend/tsconfig.json.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions