Skip to content

chore(web): upgrade frontend to TypeScript 6 - #868

Draft
lc6464 wants to merge 1 commit into
sipeed:mainfrom
lc6464:chore/upgrade-typescript-6
Draft

chore(web): upgrade frontend to TypeScript 6#868
lc6464 wants to merge 1 commit into
sipeed:mainfrom
lc6464:chore/upgrade-typescript-6

Conversation

@lc6464

@lc6464 lc6464 commented Aug 7, 2026

Copy link
Copy Markdown

Summary

This PR picks and adapts the TypeScript 6 upgrade from sipeed/NanoKVM-Pro#138 for NanoKVM.

It upgrades the web frontend from TypeScript 5.9.3 to the latest TypeScript 6 release, 6.0.3, and migrates the project configuration away from the deprecated baseUrl option. NanoKVM already uses Vite 8's native resolve.tsconfigPaths support from #853, so the NanoKVM-Pro PR's Vite alias replacement is not needed here.

Changes

  • Upgraded TypeScript from 5.9.3 to 6.0.3 and updated the pnpm lockfile.
  • Removed baseUrl with @andrewbranch/ts5to6 --fixBaseUrl; the tool confirmed that no project relies on baseUrl for module resolution and preserved the existing @/* -> ./src/* mapping.
  • Explicitly set the Vite configuration TypeScript target to ES2023, preserving the intended modern Node.js runtime target instead of adopting TypeScript 6's newer implicit default.
  • Kept Vite 8's native tsconfig path resolution unchanged.
  • No application source, backend, API, or runtime behavior changes.

Verification

  • pnpm install --frozen-lockfile with pnpm 11.20.0, including the repository's supply-chain policy check.
  • pnpm exec tsc --noEmit --stableTypeOrdering.
  • pnpm build with Vite 8.2.0 (5,339 modules transformed).
  • pnpm lint (0 errors; 15 pre-existing React Hook warnings remain).
  • Mocked login-page smoke test with playwright-cli: one application root, two inputs, and one button rendered.
  • git diff --check.

@lc6464
lc6464 marked this pull request as ready for review August 7, 2026 08:00
@watermeko
watermeko requested a review from Copilot August 7, 2026 09:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades the web/ frontend toolchain to TypeScript 6.0.3, adjusts TypeScript project configuration to remove the deprecated baseUrl setting while keeping the existing @/* -> ./src/* path mapping, and pins the Vite config TS build target for the Node-side config file.

Changes:

  • Bump typescript from ^5.9.3 to ^6.0.3 and update pnpm-lock.yaml accordingly.
  • Remove compilerOptions.baseUrl from web/tsconfig.json while retaining compilerOptions.paths.
  • Set compilerOptions.target to ES2023 in web/tsconfig.node.json (for vite.config.ts).

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
web/tsconfig.node.json Sets TS target to ES2023 for the Node/Vite config compilation context.
web/tsconfig.json Removes deprecated baseUrl while keeping the @/* path mapping.
web/pnpm-lock.yaml Updates lockfile to reflect TypeScript 6.0.3 (and peer wiring).
web/package.json Updates the TypeScript devDependency to ^6.0.3.
Files not reviewed (1)
  • web/pnpm-lock.yaml: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lc6464
lc6464 marked this pull request as draft August 10, 2026 03:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants