Maximum Velocity, Minimal Drag.
A hyper-optimized full-stack micro-framework built for AI coding agents. Server-rendered, zero hydration by default, zero config.
bun install
bun run build:client
bun run build:css
bun devOpen http://localhost:3000. That's it.
The create-thrust scaffolder lives in this repository under packages/create-thrust/.
Local usage while developing the framework:
node packages/create-thrust/bin/create-thrust.js my-appPlanned public install path after the first npm release:
bunx create-thrust my-app| Command | What it does |
|---|---|
bun dev |
Start server watch, client bundle watch, and CSS watch |
bun test |
Run all tests once |
bun test --watch |
Run tests in watch mode |
bun run build:client |
Bundle *.client.tsx browser islands into public/islands/ |
bun run build:css |
Build Tailwind CSS to public/style.css |
bun run db:reset |
Delete and recreate the database |
node packages/create-thrust/bin/create-thrust.js my-app # minimal
node packages/create-thrust/bin/create-thrust.js my-app --db # include db.ts
node packages/create-thrust/bin/create-thrust.js my-app --auth # include db.ts + auth.tsA full, concrete example of the recommended RPC + islands architecture lives in:
examples/notes-reference/
Use it when you want to see a real feature slice with:
- server-rendered page routes
- typed JSON RPC routes
- Zod validation
hono/jsx/domisland state- server tests and browser smoke coverage
Browser QA for the reference app lives in:
qa/
src/
|- index.tsx # App entry, security, mounts features
|- lib/
| |- layout.tsx # Shared HTML layout (import in features)
| |- island.tsx # Standard server-side island mount helper
| |- env.ts # Shared environment parsing and defaults
| |- db.ts # Schema + bun:sqlite connection (opt-in)
| `- auth.ts # Better Auth (opt-in)
`- features/
|- [feature].tsx # SSR route + RPC routes + schemas
|- [feature].client.tsx# Browser-only island
`- [feature].test.ts # Colocated test
Every feature stays local. Server-rendered pages, RPC routes, schemas, browser islands, and tests stay in one feature slice with a shared basename.
- Keep
src/lib/layout.tsx - Add islands only where you need interactivity
- Add
src/lib/db.tsandsrc/lib/auth.tslater if your app needs persistence or authentication - You still get a pure Hono SSR server by default
Keep everything. Add features in src/features/, tables in src/lib/db.ts, auth in src/lib/auth.ts, and small islands only for interactive UI.
| Layer | Tool | Why |
|---|---|---|
| Runtime | Bun | Fast, built-in SQLite, built-in test runner, built-in bundler |
| Server | Hono | Ultra-fast, JSX support, middleware ecosystem |
| UI | Hono JSX | Server-rendered HTML with a small client-side companion runtime |
| Interactivity | Hono RPC + Hono Client Components | Typed client/server contract with small islands |
| Validation | Zod + @hono/zod-validator | Explicit request contracts and typed validation |
| Database | bun:sqlite + Drizzle ORM | Embedded, zero setup, type-safe |
| Auth | Better Auth | Simple, framework-agnostic |
| Styling | Tailwind v4 + DaisyUI | Utility-first + custom "thrust" theme |
| Security | Hono CSRF + Secure Headers | On by default |
Thrust uses a strict interaction model designed for AI coding agents:
- page routes render HTML on the server
- RPC routes return typed JSON with explicit status codes
- browser islands call those routes with
hc() - local UI state lives in
useState()and related hooks
This keeps interactive behavior explicit and moves failures into TypeScript, validation, tests, and build output instead of browser-only DOM behavior.
Thrust uses bun:sqlite (zero deps, built into Bun) with Drizzle ORM for type-safe queries.
Schema + auto-migrate lives in one file: src/lib/db.ts. Define your Drizzle table, add a matching CREATE TABLE IF NOT EXISTS, done. Tables are created automatically on app start.
Need production migrations? Add drizzle-kit when you're ready:
bun add -d drizzle-kit better-sqlite3Then create a drizzle.config.ts pointing to your schema. See Drizzle Kit docs.
- AI-first DX - Small files, colocated logic, minimal context needed
- TDD by default - Tests live next to features. Agents verify before humans review.
- Zero config - No webpack, no vite, no next.config.js. Just Bun.
- Opt-in complexity - Start with a blank canvas, add DB, auth, and islands when you need them.
MIT