Overview
Mreact
Mreact is a React-flavored framework for building server-rendered apps.
It takes inspiration from Marko's compiler-first and streaming model, with additional influence from Solid and Qwik. It is not a resumability framework; instead, it uses compiler-assisted server/client splitting to keep server-rendered routes free of browser runtime when they do not need it.
Motivations
- Fine-grained reactivity - Use a dependency graph to update only the parts that need to change.
- Automatic server/client boundary inference - Infer which route modules and components need browser runtime so static server-rendered paths can stay server-only by default.
- Modular runtime - Avoid shipping client runtime for routes that do not need it. A route with no client-side signals can stay server-rendered without a client route bundle.
- Compile-time over runtime - Focus on the compiler rather than the runtime to avoid a fat runtime.
- Chunk-based streaming SSR - Favor memory efficiency and incremental delivery by sending HTML in chunks instead of buffering the full document, similar to Marko's streaming model.
- Dual environment optimization - Compile server and browser output separately. The server output specializes in HTML, loaders, middleware, metadata, and server actions, while the browser output specializes in DOM updates and route-local interactivity.
Status
Mreact is experimental. APIs may change.
We are dogfooding it in our own products and have tested deployments on Cloud Run, Cloudflare, and AWS Lambda.
Performance
Mreact aims to stay small and fast: small client bundles, low server rendering cost, streaming-friendly HTML, and short deployment startup paths.
See the Benchmarks page for the latest benchmark results.