Angular ships a Rust compiler preprocessor, cuts builds 2-3x
ngp, a beta compiler frontend built on the Rust toolkit Oxc, replaces Angular's reliance on a TypeScript API that version 7.0 removed. Early benchmarks show cold builds two to three times faster and memory cut nearly in half.
Angular has shipped ngp, a beta rewrite of its compiler’s analysis stage in Rust, built on Oxc, the same toolchain that powers Vite. It replaces the existing compiler’s dependency on TypeScript’s ts.Transformer API, which Microsoft’s Go-based TypeScript 7.0 rewrite removed outright, leaving Angular’s old compiler with no supported way to turn decorators like @Component into runtime code.
Benchmarks from Ninja Squad show ngp making cold builds two to three times faster than the existing compiler, and cutting peak memory from 2.8GB to 1.4GB on a 1,714-component project. You can try it now through vite-plugin-ngp, pinned to Angular 22.3.0-next.2, but the Angular team says production builds should stay on the current compiler until ngp lands in a stable Angular 22 minor release, which is gated on TypeScript 7.1 restoring the compiler API access ngp still needs.
Why it matters: this is the fix for a breaking change that was already baked into TypeScript 7.0, not an optional speed-up. If you run a large Angular codebase, the build time and memory numbers are worth testing on a branch now, ahead of the switch becoming the default.
The caveat: ngp is still beta and pinned to a specific Angular prerelease, so none of this is ready for a production build yet.