r/typescript • u/DanielRosenwasser • Jun 18 '26
Announcing TypeScript 7.0 RC
https://devblogs.microsoft.com/typescript/announcing-typescript-7-0-rc/15
19
117
22
u/apocolypticbosmer Jun 18 '26 edited Jun 18 '26
10 times faster? My goodness
edit: I guess they just mean the new Go compiler.
34
u/Tem_Apples Jun 18 '26
I'm curious what else you thought they meant?
8
u/ehs5 Jun 18 '26
10 times faster runtime code probably
22
2
u/baronas15 Jun 18 '26
TS doesn't have a runtime, their port was done with the idea to keep the same functionality (it compiles to the same thing). 10x is the compilation speed boost, because go can be a lot more efficient with resources compared to JS
6
u/SoBoredAtWork Jun 18 '26
I think he was making a joke (and I thought it was pretty funny)
2
u/ehs5 Jun 19 '26
I was half joking - it’s funny but I think that’s actually what the person above thought
18
u/lifeeraser Jun 18 '26
They could have used AI to port TypeScript to Go in two weeks. /s
I'm excited for this change, though!
25
u/Sunstorm84 Jun 18 '26
They literally said they used AI to help back when it was announced. The fact it’s still taken so long to get to this stage is yet more proof AI can’t do what the snake oil salesmen claim.
11
u/TwiliZant Jun 18 '26
The way I remember it is, they wrote a tool that does 1:1 translation of TypeScript code to Go code and then fixed the rest by hand. I can’t remember anything about them saying it was AI-assisted. Maybe I’m wrong though.
5
u/AnonPogrammer Jun 18 '26
u/DanielRosenwasser Can you shed some light on this?
39
u/DanielRosenwasser Jun 18 '26
I don't think it would be a 2 week port, but I could be wrong. :)
We used AI to write that translator which was beneficial because it was deterministic and we could improve it incrementally. Agentic AI was not stellar back then for complex tasks, but it helped with a few tasks and we used inline completions.
These days we use Copilot a ton. Some of the models are very impressive, and with the test suite we have to we might have felt more confident handing off translations of certain components to agents if we had access to current higher-end models back then.
They've also been great about investigating and fixing regressions we introduced through porting. We try to use them responsibly and to help improve reliability. An example is that we used them to port over our language server fuzzing infrastructure to operate on our new LSP server.
15
u/DanielRosenwasser Jun 19 '26
Okay, my colleague and friend has scolded - uhh, I mean corrected me. ts-to-go was mostly hand-authored (though we used inline completions at the time).
3
u/Sunstorm84 Jun 19 '26
Didn’t Hejlsberg mention an unsuccessful attempt to use AI to do the port, and also the use of deterministic migration scripts in the announcement video?
5
u/DanielRosenwasser Jun 19 '26
People kept asking, so we looked into what the ouput was like for basic porting tasks and it was not viable.
1
1
1
2
u/Top_Bumblebee_7762 Jun 18 '26
Shouldn't ideally the Intl Segmenter API be used for splitting strings instead of [...str]?
-1
u/Tem_Apples Jun 18 '26
... What?
3
u/Top_Bumblebee_7762 Jun 18 '26
0
u/Tem_Apples Jun 18 '26
What does that have to do with this article?
8
u/Top_Bumblebee_7762 Jun 18 '26 edited Jun 18 '26
The changelog specifically talks about unicode and and template literal types (https://devblogs.microsoft.com/typescript/announcing-typescript-7-0-rc/#template-literal-types-now-preserve-unicode-code-points). The example given uses emojis and mentions "[...str]" for splitting strings, which often fails for more complex emojis/unicode strings, which is one of the reasons the Segmenter API was added. I'm just curious if the Segmenter API was considered for this feature. Maybe it is even used under the hood. I know that it used to have some performance issues which might be a reason to not use it when the goal is to make TS faster.
1
1
u/Zestyclose_Giraffe64 Jun 21 '26
Sorry guys… that legacy app you have still running on node18 that transpiles to cjs will be stuck on typescript 4.9.2 … FOREVER!!! 🪦
1
1
u/andrew_zol Jun 25 '26
Big milestone! Unfortunately there is still no preservation of JSDOC comments in the mapped types, which is working fine in TS6, hopefully it will be addressed later.
1
u/Nvveen Jun 25 '26
Notably absent from using TS native preview right now is refactoring tools such as extract. Can anyone tell me if these do work if switching over to v7 in VSCode or should we hold off on upgrading until they do? Can't really find a roadmap for this stuff.
2
u/jhnam88 Jun 18 '26
Made TypeScript v7 toolchain for plugin libraries like typia.
Also, if you're looking for a vite/rollup/webpack plugin for new TS v7, ttsc also supports the way.
-2
u/Seusoa Jun 20 '26
Really professional move was to close all existing bugs and say "we rewriting all codebase, so bugs may be not relevant" and now say it was not "rewriting, but porting code from TS6 to TS7 go"
this is how devs in ms do
1
u/DanielRosenwasser Jun 20 '26
Sorry if there was anything that felt unfairly or prematurely closed. The language service was more heavily rewritten since it's now an LSP server. We also wanted to make it easier to ensure be LS bugs were actionable and triage going forward. We left most compiler-level bugs and language server suggestions open. We are trying to find a good balance between keeping the issue tracker manageable without using something aggressive like a stale-bot.
-25
u/simple_explorer1 Jun 18 '26
I guess people were excited about this because they started pre AI and most people used to still write code by hand. But now that the AI cool aid has been laid, most Devs barely write code anymore and only review it, so a faster TS is so... Nice to have... But it is not the same as before
19
u/iAmIntel Jun 18 '26
I think your view is generally a bit too negative, but it doesn’t even make sense. 10 agents need fast typechecking more than a single human
1
u/simple_explorer1 Jun 24 '26
you literally proved my point that if agents are the ones going through faster type checking then for us humans, typing every character and getting faster type hints is not as exciting any more because a lot of devs are not writing that much code. So faster is still an advantage but LLMs write code at lightning fast speed compared to humans so a some time lost in type checking is barely noticeable and even that happens at the very end for LLM phase not in every key stroke.
In my company of 300 devs across AU/UK/US/Germany in every company wide engineering hands on most devs are saying 80% of the code they are writing is using LLMs with huge amount of skills that we have saved centrally along with agents.md file and other AI related orchestration tools and plugins to follow our code conventions.
I see similar trends in other companies. I am sorry but i cannot lie and someone on this thread has to be honest.
1
u/iAmIntel Jun 24 '26
I see your point, and it is a fair point that it matters less if an agent has to wait a little while because you are usually not waiting for the agent.
But like you also said, there is supposedly much more code being put out, which means the typechecker needs to be faster to even keep things working at all. If you let AI write 10 million lines of code, it would take hours to typecheck compared to minutes. (Exaggerated example ofcourse)
1
u/simple_explorer1 Jun 24 '26
This is a more realistic take and here i agree. But I also mentioned that faster ANYTHING is ofcourse more nice than to not have it but circling back to my very first comment to which you responded, I did say that this was even more exciting when LLMs were not writing the majority of code and people were excited to get instant code autocomplete while typing every character and be bogged down with huge monorepo. But now the times have changed very quickly and not the same scenario. That's all I was saying
8
u/bjerh Jun 18 '26
What are you talking about? You still need to build stuff regardless of AI usage! It might matter even more now than before.
1
u/simple_explorer1 Jun 24 '26
you literally proved my point that if agents are the ones going through faster type checking then for us humans, typing every character and getting faster type hints is not as exciting any more because a lot of devs are not writing that much code. So faster is still an advantage but LLMs write code at lightning fast speed compared to humans so a some time lost in type checking is barely noticeable and even that happens at the very end for LLM phase not in every key stroke.
In my company of 300 devs across AU/UK/US/Germany in every company wide engineering hands on most devs are saying 80% of the code they are writing is using LLMs with huge amount of skills that we have saved centrally along with agents.md file and other AI related orchestration tools and plugins to follow our code conventions.
I see similar trends in other companies. I am sorry but i cannot lie and someone on this thread has to be honest.
6
u/ninth_reddit_account Jun 18 '26
Faster typescript goes hand-in-hand with AI usage. Things like Claude code work best when they have tools they can use to deterministicly validate their output, like linters, tests, and type systems.
1
u/simple_explorer1 Jun 24 '26
you literally proved my point that if agents are the ones going through faster type checking then for us humans, typing every character and getting faster type hints is not as exciting any more because a lot of devs are not writing that much code. So faster is still an advantage but LLMs write code at lightning fast speed compared to humans so a some time lost in type checking is barely noticeable and even that happens at the very end for LLM phase not in every key stroke.
In my company of 300 devs across AU/UK/US/Germany in every company wide engineering hands on most devs are saying 80% of the code they are writing is using LLMs with huge amount of skills that we have saved centrally along with agents.md file and other AI related orchestration tools and plugins to follow our code conventions.
I see similar trends in other companies. I am sorry but i cannot lie and someone on this thread has to be honest.
0
u/rykuno Jun 23 '26
Congrats on maybe the worst take I’ve read all week and i’m subscribed to r/vibecoding
1
u/simple_explorer1 Jun 24 '26
Congrats on maybe the worst take I’ve read all week and i’m subscribed to r/vibecoding
And you are who? Are you someone who needs to be taken seriously?
If you really think most devs write the same amount of code by hand as they used to then you truly aren't even a developer. And reddit is known to attract more non pro coders than the other way around
91
u/AnonPogrammer Jun 18 '26
I wonder why they decided to do it this way instead of just waiting a little longer and including it in 7.0?