Bump typescript from 5.9.3 to 6.0.3 - #429
Merged
Merged
Conversation
Supersedes #424, which bumped straight to TypeScript 7.0.2. That cannot land yet: typescript-eslint has no TS 7 support and is blocked upstream until the native Go compiler ships a public API (typescript-eslint/typescript-eslint#10940), so `npm run lint` crashes in ts-api-utils. TypeScript 6 is the last JS-based compiler and sits inside typescript-eslint's `<6.1.0` peer range. TypeScript 6 turns several tsconfig options into deprecation errors and drops automatic `@types` inclusion, so the config needs three changes: - `baseUrl` is deprecated and removed in 7.0; `rootDir` replaces it and has to be explicit once `baseUrl` is gone - `paths` values must be relative in 7.0 - `types: ["chrome"]` restores the `chrome` globals, which 5.9 picked up by scanning all of node_modules/@types Also refreshes @types/node 24.0.8 -> 26.1.2 in the lockfile. 24.0.8 declares `URLPattern` incompatibly with TypeScript 6's lib.dom.d.ts, which this project sees because it sets `skipLibCheck: false`. @types/tape already requests `@types/node: "*"`, so no direct dependency is needed. The emitted `distribution/` is byte-identical to the 5.9.3 output across all 108 files, so the published API is unchanged. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
grahamlangford
force-pushed
the
bump-typescript-6
branch
from
August 3, 2026 16:53
64e9a6a to
ddb64e6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Supersedes #424, which bumped straight to TypeScript 7.0.2.
Why not 7.0.2
TS 7 is the native Go compiler and does not yet expose a public compiler API, so nothing that does
require("typescript")works against it.npm run lintcrashes ints-api-utils:This is blocked upstream, not a config problem —
typescript-eslint@8.65.0and its canary both declaretypescript: >=4.8.4 <6.1.0, andts-api-utils@3.0.0-rc.1declares<7. typescript-eslint/typescript-eslint#12518 was closed as not planned, pointing at typescript-eslint/typescript-eslint#10940 as the tracker.TypeScript 6 is the last JS-based compiler and sits inside that peer range, so it gets the config migration done under deprecation errors instead of hard removals. The eventual 7.x bump becomes a one-line change once typescript-eslint lands support.
tsconfig changes
TS 6 turns several options into deprecation errors and drops automatic
@typesinclusion:baseUrl→rootDir—baseUrlis deprecated and removed in 7.0 (TS5101/TS5102); with it gone,rootDirmust be explicit (TS5011)pathsvalues made relative — non-relative values are rejected in 7.0 (TS5090)types: ["chrome"]— 5.9 auto-included all 13 packages undernode_modules/@types; 6.0 includes only import-reachable ones, which dropped thechromeglobals and produced ~35TS2304 Cannot find name 'chrome'@types/node
Refreshed 24.0.8 → 26.1.2 in the lockfile. 24.0.8 declares
URLPatternincompatibly with TS 6'slib.dom.d.ts, which this project sees because it setsskipLibCheck: false.@types/tapealready requests@types/node: "*", so this is a lockfile refresh with no new direct dependency.Verification
npm test(unit + lint + build + demo:build) passes locally, and the emitteddistribution/is byte-identical to the 5.9.3 output across all 106 files — the published API is unchanged.