App Surfaces
3
web, server, worker
A full-stack starter built for teams that want real momentum: shared UI, typed APIs, auth wired in, database ready, and live demos you can trust on day one.
Typed end-to-end from DB to UI
Web + server + worker in one repo
Reusable shadcn-based UI package
terminal
Core Stack
Features
App Surfaces
3
web, server, worker
Shared Packages
8+
ui, auth, trpc, store, common
Bootstrap Time
<10m
from clone to running stack
Type Coverage
100%
single TS contract across layers
Technology Stack
Every layer is pre-wired for real product work. No toy architecture, no “starter” compromises, no disconnected package decisions.
End-to-end type safety with tRPC. Catch errors at compile time, not runtime.
const user = await trpc.user.byId.query({ id: '1' });
console.log(user.name); // Typed!Secure authentication flows with Better Auth. Social logins, email magic links, and more.
const session = await auth.api.getSession({
headers: req.headers
});Built-in support for real-time features using Upstash Redis and Server-Sent Events.
await redis.publish('chat', JSON.stringify({
text: 'Hello World!',
userId: 'user_123'
}));Prisma ORM configured with PostgreSQL. Visual schema editing and type-safe queries.
model User {
id String @id @default(cuid())
email String @unique
posts Post[]
}Scalable Turborepo structure. Share UI components and logic across apps.
apps/
web/
server/
packages/
ui/
db/Hot reload, TypeScript, ESLint, Prettier. Everything configured for speed.
pnpm dev
> Ready in 1234msArchitecture
Workspace Map
Next.js UI + app router
Express + tRPC handlers
Background jobs + queues
shadcn-based shared design system
Prisma client + schema
Better Auth config + client
Request Flow
User interacts with web app components from packages/ui.
Typed procedures call server routers through tRPC.
Server reads/writes via Prisma and shared store package.
Realtime updates and async jobs fan out through worker + Redis.
Quick Start
This flow mirrors how teams actually onboard the template: scaffold, personalize scope, add UI primitives, then start building features.
$bun create-turbo@latest --example https://github.com/kitsunekode/template-nextjs-express-trpc-bettera-auth-monorepo my-app$cd my-app && bun install$bun run rename-scope:dry$bun run rename-scope$bunx shadcn@latest add button card dialog dropdown-menu$bun devshadcn workflow included
Add new components directly into `packages/ui` and consume them in both the app and feature demos.
bootstrap.sh
# 1) Scaffold the repo
bun create-turbo@latest --example https://github.com/kitsunekode/template-nextjs-express-trpc-bettera-auth-monorepo my-app
# 2) Install + rename package scope
cd my-app && bun install
bun run rename-scope
# 3) Add new shadcn components into packages/ui
bunx --bun shadcn@latest add button card dialog dropdown-menu -c apps/web
# 4) Start everything
bun devAdd Components
$bunx --bun shadcn@latest add button card dialog dropdown-menu -c apps/webGenerate New UI
$bun run generate:componentFunctional Proof
Click through the demos to verify real interaction patterns before writing your own features.
// Real tRPC implementation
export const chatRouter = {
list: publicProcedure.query(async () => {
return prisma.message.findMany({
orderBy: { createdAt: "asc" },
include: { sender: true },
});
}),
send: protectedProcedure
.input(z.object({ content: z.string() }))
.mutation(async ({ ctx, input }) => {
return prisma.message.create({
data: {
content: input.content,
senderId: ctx.session.user.id,
},
});
}),
}