Use TypeScript 7 RC side-by-side with TypeScript 6 compatibility#2504
Merged
Conversation
Copilot created this pull request from a session on behalf of
pethers
July 8, 2026 10:53
View session
Contributor
There was a problem hiding this comment.
Pull request overview
This PR introduces a dual-TypeScript setup so the repository can evaluate the TypeScript 7 RC compiler while keeping TypeScript 6 compatibility as the default typescript dependency.
Changes:
- Switch
typescriptto the TypeScript 6 compatibility package (npm:@typescript/typescript6@^6.0.2) and add atypescript-7alias for the TypeScript 7 RC compiler. - Add a dedicated
tsc:7script and routebuild/build:check/build:check-teststhrough it. - Update
package-lock.jsonto reflect the new alias + compatibility dependency graph.
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| package.json | Introduces tsc:7/build scripts and dual TypeScript dependencies (TS6 compatibility + TS7 RC alias). |
| package-lock.json | Locks the new @typescript/typescript6 and typescript-7 alias dependency trees and platform-specific optional deps for TS7. |
| "typedoc": "0.28.20", | ||
| "typescript": "6.0.3", | ||
| "typescript": "npm:@typescript/typescript6@^6.0.2", | ||
| "typescript-7": "npm:typescript@^7.0.1-rc", |
Comment on lines
+61
to
+64
| "tsc:7": "node ./node_modules/typescript-7/bin/tsc", | ||
| "build": "npm run tsc:7", | ||
| "build:check": "npm run tsc:7 -- --noEmit", | ||
| "build:check-tests": "npm run tsc:7 -- --project tsconfig.test.json --noEmit", |
Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
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.
The repository needed a safe path to evaluate TypeScript 7 RC without disrupting the existing TypeScript 6 toolchain. Microsoft’s compatibility model makes that possible by keeping the 6.x API available under the default package name while exposing the RC compiler through a separate entry point.
Summary
typescriptdependency and add a dedicatedtypescript-7alias for the RC compiler.tscresolution.What changed
package.jsonto use@typescript/typescript6fortypescriptand addtypescript-7fortypescript@rc.tsc:7script that invokes the TypeScript 7 RC binary directly.build,build:check, andbuild:check-teststhrough that explicit entry point.Example
{ "devDependencies": { "typescript": "npm:@typescript/typescript6@^6.0.0", "typescript-7": "npm:typescript@rc" } }