Framework

Set up and deploy your first Manic SPA application in minutes.

Framework

Manic is a zero-config React SPA framework built exclusively on Bun with ultra-fast OXC transforms, Hono API routes, and native View Transitions support.

Quick Start

bun create manic my-app
cd my-app
bun dev
npx create-manic my-app
cd my-app
npm install
npm run dev
yarn create manic my-app
cd my-app
yarn dev
pnpm create manic my-app
cd my-app
pnpm dev

Visit http://localhost:6070 (default dev port; override with server.port or manic dev --port)

What You Get

Everything is automatically wired. No webpack, no Vite, no config hell.

  • Client Router — File-based routing with lazy-loaded code splitting
  • API Routes — Hono-powered, fully typed OpenAPI
  • Build Engine — OXC transforms + Bun bundler (50-100x faster than alternatives)
  • Zero Config — Just write code, the framework figures out the rest
  • View Transitions — Native, flicker-free page navigation
  • TypeScript First — Full type safety across router, API, and config

Project Structure

index.tsx
about.tsx
index.html
manic.config.ts
~manic.ts
package.json

Next Steps

Key Concepts

The ~ Convention

Files and folders prefixed with ~ are excluded from routing. Use them for components, utilities, and tests:

index.tsx
~Header.tsx

Auto-Generated Routes

Your folder structure automatically becomes your API and site structure:

  • app/routes/blog/[slug].tsx/blog/my-post
  • app/api/users/index.tsGET /api/users
  • app/api/posts/[id].tsGET /api/posts/123

Build Pipeline

Initializing diagram...

Manic builds are deterministic and extremely fast. Most projects build in less than 1 second.

Deployment

Manic works on any Bun runtime. Choose your platform:

Vercel (Serverless Functions):

vercel

Automatic deployment on push to main.

Cloudflare (Edge Runtime):

wrangler deploy

Ultra-low latency via Cloudflare Workers.

Self-Hosted (Any Bun server):

bun start

Full Bun HTTP server. Deploy anywhere with bun run.

Ensure your deployment environment has Bun 1.0+ installed.


Have questions? Check the troubleshooting or CLI Reference guide.

On this page