Yuku — JavaScript/TypeScript Compiler and Toolchain in Zig
yuku
A high-performance JavaScript/TypeScript compiler and toolchain written in Zig, bringing modern JavaScript tooling infrastructure to the Zig ecosystem.
Why Yuku
Section titled “Why Yuku”Yuku is a JavaScript/TypeScript toolchain built from the ground up in Zig. It is designed for correctness, performance, and clarity.
Correctness first. Yuku is 100% ECMAScript spec compliant. It passes all 45,000+ tests from Test262, Babel, etc., with full AST matching, covering every edge case in the specification. Zero failures, zero AST mismatches. See the test results.
Fast by design. The parser is built using data-oriented design principles and generous performance engineering.
Pure Zig, zero dependencies. The entire toolchain is written in Zig with no external C libraries or runtime dependencies. This makes it easy to build, embed, and cross-compile.
Modern JavaScript. Full support for modern and experimental features including decorators, source phase imports, deferred imports, using/await using declarations, and more.
Current Status
Section titled “Current Status”Yuku currently provides a 100% spec-compliant, reliable, and fast JavaScript/JSX parser ready for use in Node.js and Zig, along with a Traverser. TypeScript parsing support is actively in development.
More tooling is planned (a resolver, transpiler including .d.ts generation, minifier, and more), built incrementally, one component at a time. Contributions are welcome and will help accelerate development.
Performance
Section titled “Performance”Yuku prioritizes correctness while delivering top-tier speed and efficiency. On the native (Zig/Rust) side, Yuku is competitive with Oxc:

Parsing speed for the typescript.js file (7.8 MB) · macOS (ARM) | Apple M4 Pro ·
Source
| Parser | Mean time | Memory |
|---|---|---|
| Yuku | 29.6 ms | 41 MB |
| Oxc | 30.2 ms | 53 MB |
| Swc | 64.3 ms | 89 MB |
| Parser | Mean time | Memory |
|---|---|---|
| Yuku | 48.2 ms | 89 MB |
| Oxc | 60.9 ms | 92 MB |
Benchmark source · numbers fetched at build time
On the JavaScript side (npm), Yuku is 3-5x faster than alternatives:

Parsing speed for the react.js file (72 KB) via npm packages · macOS (ARM) | Apple M4 Pro ·
Source

Parsing speed for the typescript.js file (7.8 MB) via npm packages · macOS (ARM) | Apple M4 Pro
· Source
A note on Oxc’s npm performance
You may wonder why Oxc is slower in this npm benchmark, even slower than Babel. This is because Oxc’s npm package has the overhead of passing the AST from Rust to JavaScript. What it does is serialize the AST to a JSON string on the Rust side and then call JSON.parse on the JavaScript side. This overhead makes it slower, even though Oxc is very fast at raw parsing speed.
If you benchmark Babel and Oxc by just calling their parse functions, Oxc will appear faster than Babel. This is because the program field returned by Oxc’s parse call is a getter that only runs JSON.parse when you actually access it. That deserialization is the main bottleneck, and it grows as the AST gets larger (i.e., as the source file gets longer). The npm benchmarks above measure the time to actually obtain the full AST for all parsers.
Oxc also has an experimentalRawTransfer option that makes oxc-parser roughly 2-3x faster than the results shown above. However, it is currently experimental and comes with significant limitations: it only works in Node.js (not Bun, Deno, etc.), and it allocates gigabytes of memory upfront for a single parse, leading to out-of-memory errors and failures when parsing files in parallel.
Yuku takes a different approach. Its AST is designed from the ground up to be transfer-friendly: flat, compact, and near-binary. This makes passing the AST from Zig to JavaScript fast, lightweight, and simple, without modifying the core parser. Zig’s comptime makes this safe by design. There are no multi-gigabyte allocations, only the memory the source being parsed actually needs. It works reliably on any platform and is already fully validated, passing all 45,000+ Test262 cases with exact AST matching between Zig and JavaScript. This is still an early version, with further AST transfer performance improvements already planned.