Dinou v7 — React 19 Framework

DinouBuild with React 19Deploy Everywhere

The ejectable React 19 framework built on web standards. Build full-stack apps and deploy anywhere with zero vendor lock-in.

100% React 19 Native Architecture

React Server Components. Zero Black-Box Magic.

Dinou was engineered from the ground up for React 19 primitives: native Server Components, direct Server Functions, and streaming Web standards.

0kb Client Bundle

0kb JavaScript Shipped for Server Code

Render markdown parsers, database queries, and heavy backend dependencies exclusively on the server. Dinou streams progressive React Flight chunks over standard W3C Web Streams directly into the DOM.

Architectural Guarantees
Heavy dependencies (parsers, ORMs, DB clients) stay 100% on the server
Progressive streaming over standard W3C ReadableStream
Direct database and file-system queries with zero API latency
Seamless composition with Client Components at interactive leaves
// src/dashboard/page.tsx
// Pure Server Component: 0kb sent to browser
import { db } from "@/lib/db";
import { MarkdownParser } from "@/lib/heavy-parser";
import { InteractiveChart } from "./client-chart"; // "use client"

export default async function DashboardPage() {
  // Direct database query on server
  const reports = await db.reports.findLatest();
  const summaryHtml = MarkdownParser.render(reports.raw);

  return (
    <main className="space-y-6">
      <h1>Production Analytics</h1>
      <div dangerouslySetInnerHTML={{ __html: summaryHtml }} />

      {/* Only this interactive leaf downloads client JS */}
      <InteractiveChart data={reports.metrics} />
    </main>
  );
}
Pure Server Component (0kb JS)React Flight Stream
100% compliant with React 19 specification • Zero vendor-specific patches
Universal Runtime Architecture

Deploy Everywhere. Zero Platform Lock-in.

Build your application once with React 19 Server Components. Dinou compiles it ahead-of-time to any production infrastructure in the world.

Cloudflare Workers

Edge Isolates

Sub-millisecond global cold starts across 300+ cities with native Cloudflare KV integration.

Key Advantages
  • ✓Pure W3C Web Streams (ReadableStream / TransformStream)
  • ✓Native workerd runtime with zero Node.js server dependencies
  • ✓Static assets served directly via Cloudflare global CDN (env.ASSETS)
  • ✓Automatic ISR route caching & revalidation backed by Cloudflare KV
One-Command Build
npm run build:cloudflare
Read Deployment Guide
$npm run build:cloudflare
⚡ Bundling Pass A (RSC workerd) & Pass B (SSR workerd)...
⚡ Bundling Pass C: Worker Orchestrator (.dinou/cloudflare/worker.js)...
✔ Cloudflare Workers build complete (.dinou/cloudflare/worker.js)
$npx wrangler deploy
🚀 Published to https://my-app.workers.dev (300+ edge locations)
File-System Architecture

Intuitive File-Based Routing. Zero Boilerplate.

Every folder in src/ maps directly to a clean route. Nested persistent layouts, dynamic params, route groups, and parallel slots work right out of the box.

Persistent Layout State

Nested Layouts with Zero Remounting

Every folder in src/ maps directly to a clean route. Nested layout.tsx files wrap child pages without remounting during navigation, preserving client state, audio playback, and scroll positions.

Routing ConventionDinou Standard
100%Layout State Preserved
Zero Remount Overhead: Parent layouts persist on client transitions; only changing page segments re-render.
Automatic Root Scaffolding: The root `src/layout.tsx` wraps every route with shared HTML and body shells.
Layout Escape Hatches: Use `reset_layout` or `no_layout` flags to instantly opt out of parent layout trees.
src/dashboard/layout.tsx
import { Link, type LayoutProps } from "dinou";

// Nested layout wraps all /dashboard/* child pages
export default function DashboardLayout({ children }: LayoutProps) {
  return (
    <div className="flex min-h-screen">
      {/* Persistent sidebar: never remounts across child route changes */}
      <aside className="w-64 border-r border-slate-800 p-4">
        <nav className="space-y-2">
          <Link href="/dashboard">Overview</Link>
          <Link href="/dashboard/analytics">Analytics</Link>
          <Link href="/dashboard/settings">Settings</Link>
        </nav>
      </aside>

      {/* Dynamic page content transitions smoothly */}
      <main className="flex-1 p-6">{children}</main>
    </div>
  );
}
Dinou File-System RouterZero Runtime Overhead
Dinou v7 Developer Experience

Zero-Runtime Type-Safe Routing

Eliminate dead links, catch typos at compile-time, and get instant IDE autocompletion for all your routes and parameters with zero bundle cost.

Level 1: Outward Navigation

Instant IDE Autocomplete & Dead-Link Prevention

Dinou generates TypeScript route definitions in real time. Your IDE automatically autocompletes all project paths inside <Link> and useRouter(), catching broken URLs at compile-time before reaching production.

0
Broken Links in Production
Zero-Cost
Instant autocompletion on all project routes and dynamic paths
Zero client bundle weight — resolved entirely by TypeScript compiler
src/components/navigation.tsx
import { Link, useRouter } from "dinou";

export default function Navigation() {
  const router = useRouter();

  return (
    <nav className="flex gap-4">
      {/* ✅ Instant autocompletion of all project routes */}
      <Link href="/docs/routing">Routing Guide</Link>

      {/* ✅ Typed template strings for dynamic segments */}
      <Link href={`/blog/${post.slug}`}>View Post</Link>

      {/* ✅ Relative paths, query parameters & hashes */}
      <Link href="/demo?tab=settings#profile">Settings</Link>
      <Link href="../about">About</Link>

      {/* ❌ TypeScript compile error on invalid/dead links */}
      {/* <Link href="/unknown-route">Broken Link</Link> */}

      <button onClick={() => router.push("/docs/api-reference")}>
        API Reference
      </button>
    </nav>
  );
}
Dinou Route Scanner (<2ms)TypeScript 5.x
Static by Default Architecture

Static by Default. Incremental at Scale.

Every route compiles to pre-rendered HTML and Flight payloads by default. Seamlessly scale with build-time SSG, time-based ISR, on-demand ISG, and tag-based cache purges.

Build-Time Pre-rendering

Maximum Velocity with Zero Origin Execution

Dinou is Static by Default. Routes compile into static HTML and React Flight wire payloads at build time. Use getStaticPaths to pre-render marketing pages, blogs, and documentation for instant 0ms TTFB edge delivery.

Cache MetricVerified v7
0msOrigin Server Execution
0ms Time-to-First-Byte: Served directly as static files from memory or CDN with zero runtime execution.
Global Edge Distribution: Deploy statically to Cloudflare Workers, Netlify, or any standard static host.
Zero Origin Load: Traffic spikes and viral surges never touch your origin server or database.
src/blog/[slug]/page_functions.ts
// 1. Pre-render known slugs at build time
export async function getStaticPaths() {
  const posts = await db.posts.findMany({ select: { slug: true } });

  return posts.map((post) => ({
    params: { slug: post.slug },
  }));
}

// 2. Pure static route: served permanently from edge cache
export const revalidate = false; // Never expires automatically
Dinou Static & ISR Engine0ms TTFB Edge Cache
Dinou v7 Breakthrough

Two-Dimensional Layered Segmentation

Eliminate all-or-nothing caching. Dinou v7 breaks rendering and caching into independent horizontal and vertical dimensions for ultra-fast, granular web applications.

0ms TTFB + Live Streaming

Instant Static Shell Delivery with Live Dynamic Streaming

Dinou v7 unifies static delivery and dynamic personalization in a single request. The static shell is served in under 20ms while personalized Suspense holes stream live in the background.

Real-World BenchmarkVerified v7
< 15msTime to First Byte (TTFB)
Static Prelude (Instant): Headers, navigation, layout cards and Suspense skeletons served from CDN cache.
Dynamic Stream (Live): Real-time user balances, personalized notifications and dynamic metrics stream in.
Sub-20ms Global TTFB: Edge CDNs serve the static layout shell instantly without waiting for database queries.
Atomic DOM Replacement: React 19 streaming chunks resolve Suspense boundaries and swap fallbacks seamlessly.
Inheritable or Granular: Toggle globally in dinou.config.mjs, inherit across layouts, or override per page.
src/dashboard/page_functions.ts
// 1. Enable Partial Prerendering on the route
export const ppr = true;
export const revalidate = 300; // Static shell refreshes every 5m

// src/dashboard/page.tsx
import { Suspense } from "react";
import { Skeleton } from "@/components/ui/skeleton";
import LiveUserFeed from "./user-feed";

export default function DashboardPage() {
  return (
    <div className="space-y-6">
      {/* ⚡ Static Shell: Pre-rendered & served instantly (< 20ms) */}
      <h1 className="text-2xl font-bold">Analytics Overview</h1>
      
      {/* 🌊 Dynamic Hole: Streamed over the wire when ready */}
      <Suspense fallback={<Skeleton className="h-64 w-full" />}>
        <LiveUserFeed />
      </Suspense>
    </div>
  );
}
Native React 19 RSC PipelineTypeScript 5+ Ready
Universal Lifecycle & Middleware

Universal Middleware & Webhooks. Zero SSR Overhead.

Configure global runtime behavior, intercept webhooks, inject request contexts, and enforce security policies with standard Web APIs in dinou.config.mjs.

0ms React Overhead

Short-Circuit Webhooks with Zero SSR Overhead

Handle high-frequency webhooks (Stripe, Clerk, GitHub) directly at the HTTP layer. Returning a standard Web Response short-circuits the request pipeline and completely bypasses React component rendering.

Performance GuaranteeVerified v7
< 2msWebhook Processing Time
Bypass React Rendering: Return a standard Web Response instance to abort SSR execution immediately.
Raw Body Verification: Read pristine unparsed request streams for HMAC and cryptographic webhook checks.
Universal Runtime: Runs with identical behavior across Cloudflare, Node.js, Bun, and Deno.
dinou.config.mjs
import { defineConfig } from "dinou";

export default defineConfig({
  plugins: [
    {
      name: "stripe-webhooks",
      async onRequest(request) {
        const url = new URL(request.url);

        // Fast-path webhooks: short-circuit before React renders
        if (url.pathname === "/api/webhooks/stripe") {
          const signature = request.headers.get("stripe-signature");
          const payload = await request.text();
          await stripe.events.verify(payload, signature);

          // Returns pure Web Standard Response in < 2ms
          return Response.json({ received: true }, { status: 200 });
        }
      },
    },
  ],
});
Dinou Plugin PipelineStandard Request / Response
Developer Velocity

Lightning-Fast Developer Experience. Instant Iteration.

Built from scratch for sub-millisecond Hot Module Replacement (HMR), zero-fork in-memory compilation, instant route scanning, and instant terminal feedback.

Instant State Preservation

Instant HMR That Never Drops Component State

Dinou's custom WebSocket HMR server and React Refresh integration patch updates into your running application in under 5 milliseconds. Active form fields, counters, and scroll positions stay perfectly intact.

Developer BenchmarkVerified v7
< 5msAverage HMR Patch Latency
Sub-5ms Hot Patching: WebSocket-driven module replacement pushes changes without full page reloads.
Zero State Loss: React Refresh boundaries preserve component state, timers, and client inputs.
Surgical Cache Invalidation: Dependency manifests track exact module trees to avoid redundant work.
src/components/counter.tsx
"use client";

import { useState } from "react";

export function Counter() {
  // ✅ State is 100% preserved during live component editing!
  const [count, setCount] = useState(42);

  return (
    <div className="flex items-center gap-4 p-6 rounded-2xl bg-slate-900 border border-slate-800">
      <span className="text-3xl font-bold font-mono text-amber-400">{count}</span>
      <button
        onClick={() => setCount((c) => c + 1)}
        className="px-4 py-2 bg-amber-500 hover:bg-amber-400 text-slate-950 font-semibold rounded-xl transition-colors"
      >
        Increment
      </button>
    </div>
  );
}
Dinou In-Process Dev ServerWebSocket HMR Active
Multi-Bundler Freedom

Choose Your Bundler. Swap Whenever You Want.

Never be locked into a single proprietary compiler. Dinou v7 supports pre-configured, zero-config pipelines for the three premier JavaScript bundlers.

Default & Lightning FastGo Binary

esbuild

Instant Local Development

Sub-millisecond build cycles and instant HMR feedback loops for your everyday dev server.

< 5msRebuild Latency
dinou dev
Best for: Ultra-fast local iteration
Optimized Tree-ShakingPure ESM Engine

Rollup

Pristine ES Module Output

Surgical code-splitting and dead-code elimination. The optimal choice for Cloudflare Workers and Edge Isolates.

0% UnusedBundle Stripping
dinou build:rollup
Best for: Edge isolates & serverless
Enterprise EcosystemEnterprise Battle-Tested

Webpack

Maximum Package Compatibility

Full compatibility with legacy npm dependencies and seamless native React Compiler pipeline integration.

100%Ecosystem Coverage
dinou build:webpack
Best for: Enterprise & React Compiler

Identical Dual-Bundle Output Across All Three Engines

Swap bundlers anytime without refactoring application components or routing.

Bundlers Guide
Framework Sovereignty

Eject Anytime. Own Your Entire Stack.

Zero vendor lock-in. A single command extracts Dinou's complete compiler, server runtime, and React 19 flight pipeline directly into your project.

./dinou/
Full Source Code
compiler/Dual-Bundle AOT Compiler

Pluggable build pipelines for esbuild, Rollup, and Webpack.

server/Universal Server Adapters

Multi-runtime server loop for Cloudflare, Bun, Node, and Deno.

client/Hydration & Navigation

Progressive client hydration runtime, <Link>, and router.

rsc-context/React Flight Wire Protocol

Serializes Server Components and dispatches Server Functions.

static-isr/Hybrid Cache & ISR Engine

Static site generation and granular layout revalidation.

$npx dinou eject
Why Ejection Matters

Freedom to Evolve Your Architecture

Zero Risk of Abandonment

You are never at the mercy of closed cloud vendors or breaking meta-framework changes. Your codebase is 100% self-contained.

Custom Server & Middleware Control

Add custom HTTP headers, edge telemetry, WebSockets, or caching policies directly inside your server loop with standard Node or web APIs.

Built for Modern AI Workflows

AI coding assistants can inspect and modify your exact compiler and streaming code directly, eliminating black-box roadblocks.

Learn more about framework sovereignty.Eject Documentation
Architectural Metamorphosis

Not Just a Version Bump. A Ground-Up Metamorphosis.

Dinou v7 is not an incremental update—it is an entirely re-engineered foundation. We eliminated child processes, Express, and runtime compilation hacks in favor of pure in-process Web Standards.

🏎️

Dinou v7Modern AOT

Streamlined & Universal
Modern Core

Built as a unified in-process engine using native W3C Web Streams and React 19 standards. Server Components (RSC) and SSR stream directly in memory with instant response times and zero subprocess overhead.

Direct in-memory streaming with zero subprocess overhead
100% W3C Web Standards: zero Express, zero runtime transforms
Deploy to Edge, Bun, Deno, Node.js, native binaries, and SSG
Dinou v7 Architectural SpecificationsVerified v7 Standard
Architectural DimensionDinou v7 Implementation
RSC & SSR ArchitectureNative in-process streaming via React 19 Web Streams
Runtime Standards100% W3C Web APIs (Request, Response, ReadableStream) — zero Express
Process & Memory ModelSingle-process unified memory-mapped engine with flat, predictable RAM
Deployment FlexibilityUniversal: Cloudflare Workers, Bun, Deno, Node.js & native single binaries
Dev Server & DXIn-memory 0-fork compilation with sub-5ms WebSocket HMR (< 150ms startup)
Rendering & Caching Model2D Layered Segmentation (PPR, layout_functions & <DinouCacheSlot>)
State Persistence on NavigationPersistent nested layouts across sibling transitions (zero layout remounting)
Start Building Today

Ready to build without boundaries?

Experience the power of React 19 Server Components, Streaming SSR, and Server Functions with total freedom of infrastructure.