Skip to content

kao-xiang/mantou

Repository files navigation

MANTOU 🍞

The Next Generation Web Framework Powered by Bun

preview Effortless Fullstack: Typesafe & Documented.

license last-commit repo-top-language

Discord Reddit

🌟 Overview

MANTOU (馒倴) is a delightfully simple yet powerful web framework that brings together the best of Next.js patterns with Bun's blazing speed. Like its namesake - the fluffy Chinese steamed bun - MANTOU is light, satisfying, and gets the job done without unnecessary complexity.

⚑️ Key Features

  • 0ms Cold Start: Powered by Bun's lightning-fast runtime
  • Type Safety Without Tears: Automatic type inference that just works
  • File-Based Magic: Next.js-style routing you already know and love
  • API Docs That Write Themselves: Automatic Swagger generation
  • Hot Like πŸ”₯: Ultra-fast hot module replacement
  • Zero Config: Sensible defaults with full customization when you need it

πŸš€ Quick Start

# Create your next amazing project
bun create mantou-app@latest

# Jump into the action
cd my-app
bun install
bun run dev

Later in Documentation

🎯 Roadmap

Phase 1

  • File-based routing system
  • Basic SSR implementation
  • Type-safe API routes
  • Production build optimization
  • Websocket Integration
  • Plugins

🎨 Why Choose MANTOU?

Simple Yet Powerful

Like a steamed bun, MANTOU is simple on the outside but packed with goodness inside. We eliminate complexity while keeping the power you need.

Performance First

Built on Bun, MANTOU is designed for speed:

  • Sub-millisecond cold starts
  • Lightning-fast HMR
  • Optimized build output
  • Minimal runtime overhead

πŸ›  Configuration

// mantou.config.ts
export default {
  swagger: {
    path: '/docs',
    documentation: {
      info: {
        title: 'Mantou Example',
        description: 'Mantou Example API',
        version: '1.0.0',
      },
      security: [{ JwtAuth: [] }],
      components: {
        securitySchemes: {
          JwtAuth: {
            type: "http",
            scheme: "bearer",
            bearerFormat: "JWT",
            description: "Enter JWT Bearer token **_only_**",
          },
        },
      },
    }
  }
}

🀝 Contributing

We love contributions! Here's how you can help:

  1. Fork the repo
  2. Create your feature branch
  3. Make your changes
  4. Submit a PR

See our Contributing Guide for more details.

πŸ“˜ Documentation

Visit this for full documentation.

πŸ’¬ Community

πŸ“„ License

MIT License - feel free to use and modify!