Show HN: rari, the rust-powered react framework
A new framework, Rari, aims to accelerate React applications by leveraging Rust for its server runtime, offering built-in React Server Components and optimized bundling. Its debut sparked keen interest among developers, eager for faster React performance. However, the initial documentation was a source of confusion, leading to lively discussion about its core architecture and comparison to existing solutions like Deno and Bun.
The Lowdown
Rari (Runtime Accelerated Rendering Infrastructure) is a new framework designed to bring native-speed performance to React applications. It distinguishes itself by utilizing Rust for its core server runtime, which handles HTTP, React Server Components (RSCs) rendering, and routing, all while executing JavaScript components via an embedded V8 engine. The project promises blazing-fast builds and runtime, zero configuration thanks to the Rust-based Rolldown-Vite bundler, and comprehensive TypeScript support with tsgo for rapid type checking.
Key features highlighted:
- Rust-Powered Performance: The entire server runtime, including RSC rendering, is written in Rust, aiming for superior speed compared to Node.js alternatives.
- React Server Components (RSCs): Offers native, built-in support for RSCs to minimize client-side JavaScript.
- Optimized Tooling: Leverages Rolldown-Vite for lightning-fast bundling and
tsgofor 10x faster TypeScript checks. - Developer Experience: Provides instant Hot Module Replacement (HMR) and detailed error messages.
- NPM Integration: Uniquely handles traditional
node_modulesresolution within its Rust runtime, unlike some other Rust-based JS runtimes.
Rari positions itself as a streamlined path to high-performance React applications, focusing on developer experience and efficiency by offloading heavy lifting to Rust-native processes.
The Gossip
Clarifying Core Concepts
Many commenters were initially confused about what 'Rust-powered' specifically meant for rari, with some assuming it only referred to the bundler. The author clarified that the Rust component extends to the entire server runtime, including HTTP serving, RSC rendering, and routing, which uses an embedded V8 engine for JavaScript execution. This distinction was crucial for understanding the framework's novelty and potential performance benefits.
Documentation Dilemmas
There was significant feedback regarding the clarity and completeness of rari's documentation. Commenters noted that the website's descriptions were vague and at times misleading, with some phrases sounding like AI-generated boilerplate. The author acknowledged these shortcomings, attributing them to solo development efforts and a focus on core runtime stability, and welcomed community contributions to improve the documentation and messaging.
Performance Puzzles and Comparisons
Despite rari's focus on performance, the initial launch experienced a 'hug of death' with the website becoming inaccessible for some users, which ironically challenged its performance claims. The author explained this was due to an 'overzealous' rate limiter, not the framework itself. Discussion also emerged comparing rari to other Rust-based runtimes like Deno (which also uses Rust for its HTTP server) and querying its performance against Node.js and Bun, signaling a strong interest in practical benchmarks.