TypeScript 7.0 RC

DanRosenwasser1 pts0 comments

Announcing TypeScript 7.0 RC - TypeScript

Skip to main content

Dev Blogs

AI

All .NET posts

.NET MAUI<br>ASP.NET Core<br>Blazor<br>Entity Framework

C++<br>C#<br>F#<br>TypeScript

NuGet<br>Servicing<br>.NET Blog in Chinese

Microsoft for Developers<br>Agent Framework<br>Develop from the cloud<br>Xcode<br>ISE Developer<br>TypeScript<br>PowerShell<br>Python<br>Java<br>Java Blog in Chinese<br>Go<br>Microsoft Edge Dev<br>Microsoft 365 Developer<br>Microsoft Entra Identity Developer<br>Microsoft Entra PowerShell

Visual Studio<br>Visual Studio Code<br>Aspire

All things Azure<br>Azure SDK<br>Azure VM Runtime Team<br>Microsoft Azure<br>Azure Cosmos DB<br>Azure DocumentDB<br>Azure Data Studio<br>Azure SQL<br>DevOps<br>DirectX<br>Microsoft Foundry<br>Power Platform

OData<br>Unified Data Model (IDEAs)

Windows Command Line<br>#ifdef Windows<br>Inside MSIX<br>MIDI and music<br>React Native<br>The Old New Thing<br>Windows Developer

Daniel Rosenwasser

Principal Product Manager

Today we are excited to announce the Release Candidate of TypeScript 7.0!

If you haven’t been following TypeScript 7.0’s development, this release is significant in that it is built on a completely new foundation.<br>Over the past year, we have been porting the existing TypeScript codebase from TypeScript (as a bootstrapped codebase that compiles to JavaScript) over to Go.<br>With a combination of native code speed and shared memory parallelism, TypeScript 7.0 is often about 10 times faster than TypeScript 6.0.

To get the new compiler, you can just install it from the typescript package on npm, just like with any other release:

npm install -D typescript@rc

The new Go codebase was methodically ported from our existing implementation rather than rewritten from scratch, and its type-checking logic is structurally identical to TypeScript 6.0.<br>This architectural parity ensures the compiler continues to enforce the exact same semantics you already rely on.<br>TypeScript 7.0 has been evaluated against the enormous test suite we’ve built up over the span of a decade, and is already in use in multiple multi-million line-of-code codebases both inside and outside Microsoft.<br>It is highly stable, highly compatible, and ready to be put to the test in your daily workflows and CI pipelines today.

For over a year we’ve been working with many internal Microsoft teams, along with teams at companies like Bloomberg, Canva, Figma, Google, Lattice, Linear, Miro, Notion, Slack, Vanta, Vercel, VoidZero, and more to try out pre-release builds of TypeScript 7.0 on their codebases.<br>The feedback has been overwhelmingly positive, with many teams reporting similar speedups, shaving off a majority of their build times, and enjoying a much more lightweight and fluid editing experience.<br>In turn, we feel confident that the release candidate is in great shape, and we can’t wait for you to try it out.

Using TypeScript 7.0 RC

As mentioned above, to get TypeScript 7.0 RC, you can install it via npm:

npm install -D typescript@rc

From there, you can run tsc just like with any prior version of TypeScript, and you should see the same results as before – just much faster!

> npx tsc --version<br>Version 7.0.1-rc

To try out the editing experience, you can install the TypeScript Native Preview extension for VS Code.<br>The editor support is rock-solid, and has been widely used by many teams for months now.<br>It’s an easy low-friction way to try TypeScript 7.0 out on your codebase immediately.<br>It uses the same foundation as the command line experience, so you get the same performance improvements in your editor as you do on the command line.<br>Notably, it’s also built on the Language Server Protocol (LSP), making it easy to run in most modern editors or even tools like Copilot CLI.

Running Side-by-Side with TypeScript 6.0

Even though 7.0 RC is close to production-ready, we won’t have a stable programmatic API available until at least several months from now with TypeScript 7.1.<br>Given this, we have made it a priority to ensure TypeScript can be run side-by-side with TypeScript 6.0 for the foreseeable future without any conflicts around "which tsc is which?"

As part of the 6.0/7.0 transition process, we’ve published a new compatibility package, @typescript/typescript6.<br>This package provides an executable named tsc6, so that if needed, you can install TypeScript 7.0 (which ships its own tsc binary) side-by-side without naming conflicts.<br>The new package also re-exports the TypeScript 6.0 API, so that you can use tsc for TypeScript 7, while other tooling can continue to rely on 6.0.

Because some tools like typescript-eslint expect to import from typescript directly via peer dependencies, we recommend achieving this via npm aliases.<br>You should be able to run the following command

npm install -D typescript@npm:@typescript/typescript6

or modify your package.json as follows:

"devDependencies": {<br>"typescript": "npm:@typescript/typescript6@^6.0.0",

Note that doing this will leave you only with a tsc6 executable.<br>To get 7.0’s tsc, you can add another alias for TypeScript 7 and npx tsc will just work with...

typescript microsoft from azure install side

Related Articles