πŸ“ˆ GH Trending Explorer 🎲 Surprise me

← all repos

pingdotgg / ts-rust

git clone https://github.com/pingdotgg/ts-rust.git v0.7.0 Β· 6d ago

An experimental Rust port of the TypeScript 7 compiler (tsc)

β€”
stars, 24h
β€”
stars, 7 days
+1.4k
stars, 30 days Β· #219
1.4k
β˜… total
95
forks Β· 20 open issues

Star history starts 2026-10-20; the chart appears after the second daily snapshot.

LanguageRust
LicenseMIT
Created2026-10-07 (13d ago)
Last pushtoday
Watchers3
OwnerOrganization

GitHub topics

Links

README excerpt
# ts-rust (aka tsc-rs)
I wanted to see if LLMs could port the TypeScript compiler, checker and lsp to Rust. Turns out they can.
It cost over $420,000 in tokens to do it, but you could probably have done it for ~$20k (see below).
## Benchmark: T3 Code with Effect diagnostics
Full type check of T3 Code with Effect diagnostics on.\*
Time is the sum of the medians for its five checked projects. Lower is faster. Bar length is
in proportion to time. See Benchmark: T3 Code for the method and the run
without Effect diagnostics.
| Checker | Time | Relative time | Speed vs tsc 7 |
| --- | ---: | --- | ---: |
| `tsc-rs --fast` | 9.77s | β–ˆ | 4.35Γ— |
| `tsc-rs` | 14.30s | β–ˆβ–ˆ | 2.98Γ— |
| `tsc` 7 | 42.55s | β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | baseline |
| `bun check` | 59.24s | β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 0.72Γ— |
| `tsc` 6 | 191.00s | β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 0.22Γ— |
\* `tsc-rs` is 0.6.0 with Effect diagnostics built in. `tsc` 7 is from `@effect/tsgo`. The
`bun check` time adds a separate `effect-tsgo diagnostics` run. `tsc` 6 uses the JavaScript
Effect plugin.
## Motivations
- Test model capabilities
- Make a fast TypeScript type checker
- Make a ts checker that can work in WASM with high performance
- Memes
## Warnings
**This is an early release.** It has 100% compatibility in every real world project we have
tested. It should work as a drop in
replacement for the vast majority of apps. See Known problems.
Also worth mentioning: I've never read a line of this code.
## Install
Be warned, I have no idea if this will actually work.
 [code] 
## How did this go?
I used a lot of OpenAI models to try and complete this port. In total I did **over $400,000 in API priced tokens with GPT-5.6 Sol and GPT 6 Astra**. They wrote over 1.3m lines of Rust over multiple months of /goal loops and never got past like 84% compat.
When I saw how little my Claude Code limits were burning, I figured it'd be fun to throw Opus 5.5 at this. It had a working v0 in 10 hours.
I assumed it kept using the code the Codex models wrote. I was wrong. **Opus 5.5 started from scratch. It got further than Astra in 1/10th the time.**
I let it keep going, and it definitely did. Total token spend was **~$24,047 of API spend over 2 weeks**. I was using my Claude accounts, and it worked out to somewhere between **925% and 983% of my $200 plan weekly limits**.
Expensive, for sure, but not that bad considering how much work has gone into typescript-go.
# "The Slop Line"
Everything below this was written by my LLMs, not me. 
## What actually is this?
ts-rust is a direct port of Microsoft's native TypeScript compiler, which is written in Go
(microsoft/TypeScript, formerly
typescript-go). It keeps Go's algorithms and
behavior and has the same command line (`tsc`), language server and API.
## Install
 [code] 
`tsc-rs` takes the same options as `tsc`. The npm package is `tsc-rs` so that it does not clash
with the `typescript` package. Each release also
has a standalone archive per platform: the `tsc` binary with the lib files next to it.
Platforms: Linu