Skip to content

darylcecile/catmint

Repository files navigation

Catmint

A TypeScript-first, full-stack React framework inspired by Next.js and TanStack Router/Start.

Catmint gives developers explicit control over rendering, caching, and server/client boundaries without hidden magic. It supports three deployment modes (backend-only, frontend-only, full-stack) and provides file-based routing, server functions, and React Server Components out of the box.

Note

Catmint is in early alpha. The API is not yet stable and may change without a major version bump. Feedback and contributions are welcome! See the contributing guide for details. Docs

Features

  • File-based routing with type-safe route manifest generation
  • React Server Components with streaming support
  • Server functions via createServerFn and createIsomorphicFn
  • MDX support with build-time compilation and runtime rendering
  • Layouts and middleware with file-based resolution and inheritance
  • Typed environment variables with CATMINT_PUBLIC_* convention
  • Isomorphic cookies API
  • Head and metadata management
  • Internationalization with locale-based routing
  • OpenTelemetry integration for analytics and observability

Getting Started

Create a new project

npm create catmint@latest

Or set up manually

pnpm install
pnpm dev

Open http://localhost:6468 in your browser.

Project Structure

app/
├── layout.tsx          # Root layout
├── page.tsx            # Home page (/)
├── about/
│   └── page.tsx        # /about
├── api/
│   └── hello/
│       └── endpoint.ts # API endpoint
├── data.fn.ts          # Server function
└── public/
    └── favicon.ico     # Static assets

Packages

Package Description
catmint Core framework (routing, layouts, middleware, hooks, MDX, etc.)
@catmint/cli CLI for dev, build, start, and generate commands
@catmint/vite Vite plugin for MDX, server functions, env transforms, and more
create-catmint Project scaffolding (npm create catmint)
@catmint/adapter-node Node.js production server adapter
@catmint/adapter-vercel Vercel deployment adapter
@catmint/adapter-cloudflare Cloudflare Workers deployment adapter

Scripts

  • pnpm dev -- Start development server
  • pnpm build -- Build all packages
  • pnpm test -- Run tests
  • pnpm test:watch -- Run tests in watch mode
  • pnpm test:typecheck -- Run type-checking tests
  • pnpm lint -- Type-check with tsc --noEmit
  • pnpm format -- Format with Prettier

Requirements

  • Node.js >= 20
  • pnpm 9.15.0+
  • React 19

License

GNU General Public License v2 -- see LICENSE for details.

About

A proof-of-concept react framework, to illustrate what i want from a react framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors