同时提供 React(Next.js 16 + Turbopack + Zustand)与 Vue(Vue.js 3 + Vite + Pinia)两套完整模板
gramkit — Next.js 启动器模板
作者 AHTOOOXA
gramkit 是一个面向 Telegram Mini App 与 Web 应用的 monorepo 模板,提供 React(Next.js)与 Vue 两套前端、共享 FastAPI 后端核心,以及认证、支付、类型安全 API 等模块。
看看你的网站会是什么样
浏览真实页面截图,比较内容排版与手机效果。点击下方缩略图切换,放大查看整页细节。
全部页面与视图 2
截图用于了解视觉与布局,交互效果请以实际项目为准。
值得关注的模板亮点
从已有项目资料中,快速了解它的特点。
共享 core/ 后端与前端组件,避免在多个应用间复制代码
内置认证体系:邮箱+OTP、Telegram OAuth、密码重置、账号关联与会话管理
通过 OpenAPI → Kubb 自动生成 TypeScript hooks,实现前后端类型安全
Telegram 能力可选,留空 BOT__TOKEN 即退化为标准 Web 应用
包含面向 Claude Code 的四层编排架构与结构化任务系统
模板详细介绍
gramkit 是一个 monorepo 模板,仓库 README 将其定位为用于 Telegram Mini App 和 Web 应用的「生产就绪」模板。它提供两套完整前端模板:React 版本基于 Next.js 16 + Turbopack + Zustand,Vue 版本基于 Vue.js 3 + Vite + Pinia,两者共用 core/ 目录下的 FastAPI、SQLAlchemy 后端与共享组件,避免在项目间复制粘贴。
功能层面,README 列出认证(邮箱+OTP、Telegram OAuth、密码重置、账号关联)、基于角色的访问控制、实时数据(WebSocket、轮询、AI 流式、乐观更新)、移动优先布局与 Telegram Mini App 检测、由 OpenAPI 经 Kubb 自动生成的 TypeScript hooks、i18n 与明暗主题、YooKassa 与 Telegram Stars 支付、以及基于 ARQ 的后台任务。Telegram 相关能力为可选:将 BOT__TOKEN 留空即得到标准 Web 应用。
开发与运行方面,模板支持两种模式:直接 localhost 模式使用原生 Turbopack,前端在本地运行并直连 API;隧道模式通过 nginx + Cloudflare Tunnel 提供 HTTPS,用于 Telegram Mini App 测试。项目还包含面向 Claude Code 的编排架构(命令、技能、子代理与模式文档)、结构化任务系统、基于 testcontainers 与 pytest 的测试方案,以及统一的 Makefile 命令。README 未说明这些功能的性能表现或实际生产验证情况,也未提供除 MIT 许可外的更多授权细节。
适合你的项目吗?
适用场景
- 需要同时评估 React 与 Vue 两种前端实现方式的 Telegram Mini App 项目
- 希望以共享后端核心快速搭建多个 Web 应用并统一维护的团队
- 需要邮箱+OTP 与 Telegram OAuth 双认证、角色权限及支付集成的应用
- 使用 Claude Code 进行 AI 辅助开发并希望沿用其命令与任务编排流程的项目
- 需要在本地 HTTPS 隧道环境下测试 Telegram WebApp 认证的开发者
适合人群
- 熟悉 Docker、Make、pnpm 与 Python 环境配置的全栈开发者
- 计划构建 Telegram Mini App 或纯 Web 应用并需要现成认证与支付模块的团队
- 偏好 monorepo 架构、希望前后端类型同步的项目维护者
- 在 Vue 与 React 之间尚未定夺、想基于同一套模式做对比选型的开发者
上手与定制指南
结合仓库当前版本的说明,按下面的资料检查内容、配置与运行要求。
- 1
需先安装 Docker & Docker Compose、Node.js 20+ 与 pnpm、Python 3.14+ 以及 Make
- 2
克隆仓库后进入 apps/template-vue 或 apps/template-react,复制 .env.example 为 .env 并按需修改
- 3
使用 make up APP=<模板名> 启动服务;localhost 模式访问 http://localhost:3001/template-react 或 http://localhost:5174/template-vue
- 4
Telegram Mini App 测试需配置 Cloudflare Tunnel 与 nginx,访问 https://local.gramkit.dev/template-react
- 5
Telegram Bot Token 与 Cloudflare Tunnel 为可选项;不配置 Bot Token 时应用以标准 Web 应用运行
授权与来源资料
使用条件与限制
免费使用 · 保留许可声明本次收录的是公开仓库中采用 MIT 许可的免费版本;免费范围为该版本代码,不代表外部服务或第三方素材免费。
使用时需要遵守
- 允许免费使用、修改、商用和分发该版本代码。
- 分发代码副本或实质性部分时,保留原作者版权声明和完整 MIT 许可声明。
- 代码按现状提供;担保与责任限制以原许可证及适用法律为准。
额外费用与待核对事项
- 演示图片、字体、图标及其他第三方素材需按各自许可核对,不能仅凭代码的 MIT 许可判断。
- 域名、托管、数据库、支付或 AI 等外部服务可能另外收费。
- Telegram Bot Token 为可选,但若需启用 Telegram 相关功能,需从 @BotFather 获取 Bot Token。
- Cloudflare Tunnel 为可选,但若需在 HTTPS 隧道环境下测试 Telegram Mini App,需使用 Cloudflare Tunnel。
- 支付功能依赖 YooKassa 集成与 Telegram Stars,使用相关支付能力可能需要相应第三方账户或配置。
查看原文依据
Permission is hereby granted, free of charge
许可证原文
- Telegram Bot Token (from @BotFather)
README 原文
- Cloudflare Tunnel (for TMA testing)
README 原文
https://github.com/AHTOOOXA/gramkit/blob/main/LICENSEhttps://github.com/AHTOOOXA/gramkit/blob/main/README.md| **Payments** | YooKassa integration, Telegram Stars, subscription billing |
README 原文
DeepSeek 根据仓库许可证和 README 整理 ·2026-10-14。结果仅覆盖已读取资料,依赖、图片、字体及后续条款变更以各自原文为准。
项目核对记录与介绍依据
模板资料
- 来源平台
- GitHub
- 资料与维护参考分
- 资料较完整 · 88 / 100
- 技术栈
- Next.js · Vue · React
- 网站类型
- 启动器
这个分数如何计算
本站按许可资料(最高30分)、演示链接(12分)、预览图(10分)、Star数(15分)、记录的维护时间(15分)、描述完整度(8分)、功能记录(5分)和分类资料(5分)计算。它不是代码、安全或性能测试,也不是 Google 评分;有链接不代表已实测可用。
这个项目需要核对什么
- 记录的仓库更新时间
- 2026-01-05
- 截图检查日期
- 2026-10-14
已收录演示链接。请用你的内容与屏幕尺寸检查;有演示不代表表单、认证或支付已经可用。
目录记录的主要技术栈是 Next.js。请通过依赖清单和锁文件核对实际版本与托管要求。这些说明基于收录资料,不代表代码审计或部署实测。
查看具体选型方法 →介绍的制作与核对状态
介绍由 AI 辅助整理目录与仓库资料。仓库作者不等于这篇介绍的审核者。
审核声明: codex-user-requested-batch-review-20261017 · 2026-10-16
查看当时使用的来源资料
SHA-256: c14670b1e641814f84dc90ba758d4180f5231100941da5ee1efd5f464d5ef2ed
2026-10-14T11:37:04.491Z
来源文件 / 仓库# gramkit Production-ready monorepo for Telegram Mini Apps and web applications. Vue.js or React. Telegram-native or web-only. Type-safe from database to UI. **[Live Demo (React)](https://react.antonchaynik.ru)** · [Live Demo (Vue)](https://vue.antonchaynik.ru) ## Features | Feature | What You Get | |---------|--------------| | **Authentication** | Email + OTP verification, Telegram OAuth, password reset, account linking | | **Role-Based Access** | Admin/Owner/User roles, protected routes, permission checks | | **Real-Time Data** | WebSocket, polling, AI streaming, optimistic updates | | **Mobile-First** | Responsive layouts, bottom navigation, Telegram Mini App detection | | **Type-Safe API** | Auto-generated TypeScript hooks from OpenAPI schema (Kubb) | | **i18n + Theming** | Multi-language support, dark/light mode out of the box | | **Payments** | YooKassa integration, Telegram Stars, subscription billing | | **Background Jobs** | ARQ for async tasks, email sending, scheduled jobs | > Telegram features are opt-in. Leave `BOT__TOKEN` empty and you have a standard web app. ## What's Included ### Two Complete Templates | Template | Stack | Best For | Demo | |----------|-------|----------|------| | **React** | Next.js 16 + Turbopack + Zustand | SSR, React 19, larger ecosystem | [react.antonchaynik.ru](https://react.antonchaynik.ru) | | **Vue** | Vue.js 3 + Vite + Pinia | Lighter bundle, simpler state | [vue.antonchaynik.ru](https://vue.antonchaynik.ru) | Both include: - **5 production pages** — Home, demos, profile, admin, auth flows - **17 tech demos** — Caching, mutations, infinite scroll, streaming, suspense - **Full auth system** — Email+OTP, Telegram OAuth, password reset, session management - **Tailwind CSS + shadcn** — Consistent design system, dark mode ### Shared Core ``` core/ ├── backend/ # FastAPI, SQLAlchemy, auth, payments, email ├── frontend/ # Vue.js shared components └── frontend-react/ # React shared components ``` Write once in `core/`, import into any app. No copy-paste between projects. ## Tech Stack | Layer | Technology | |-------|------------| | Backend | Python 3.14+, FastAPI, SQLAlchemy 2.0, Alembic, Pydantic | | Frontend (Vue) | Vue.js 3, Vite, TanStack Query, Pinia, shadcn-vue | | Frontend (React) | Next.js 16, Turbopack, TanStack Query, Zustand, shadcn/ui | | Database | PostgreSQL, Redis | | Styling | Tailwind CSS 3, CSS variables theming | | Type Generation | OpenAPI → Kubb → TypeScript hooks | | Optional | aiogram 3.x (Telegram Bot), Cloudflare Tunnel | ## Two Development Modes ### Direct Localhost (Recommended) Native Turbopack — fastest iteration, no Docker overhead for frontend. ``` http://localhost:3001/template-react http://localhost:5174/template-vue ``` - ~10x faster warm starts with Turbopack cache - Frontend runs natively on your machine - Direct API calls (CORS enabled in dev) ### Tunnel Mode Via nginx + Cloudflare tunnel — for Telegram Mini App testing. ``` https://local.gramkit.dev/template-react https://local.gramkit.dev/template-vue ``` - HTTPS with valid certificate - Telegram WebApp authentication works - Production-like environment ## Quick Start ```bash # Clone git clone https://github.com/AHTOOOXA/gramkit.git cd gramkit # Choose template cd apps/template-vue # Vue.js cd apps/template-react # React/Next.js # Setup cp .env.example .env # Edit with your settings # Start make up APP=template-vue # or APP=template-react # Open # Localhost: http://localhost:3001/template-react or http://localhost:5174/template-vue # Tunnel: https://local.gramkit.dev/template-react ``` ### Create Your Own App ```bash cp -r apps/template-react apps/myapp # Update: package.json, docker-compose.yml, .env make upgrade APP=myapp make up APP=myapp ``` ## Built for Claude Code 4-layer orchestration architecture — context-efficient, parallel-ready. ``` Layer 0: CLAUDE.md → Orchestration rules, quick reference Layer 1: .claude/commands/ → /develop, /create-task, /execute-task, /review Layer 2: .claude/skills/ → Auto-invoked procedures Layer 3: .claude/agents/ → developer-agent, testing-polish-agent ``` ### Slash Commands | Command | What It Does | |---------|--------------| | `/create-task` | PRD → phases → parallel enrichment agents | | `/execute-task` | Phase-by-phase execution with auto-commits | | `/develop` | Quick delegation to developer-agent | | `/design` | Research approaches, compare options | | `/review` | Deep architectural review | | `/add-testing` | Add test phases to existing task | ### Pattern Docs 10 docs in `.claude/shared/` that agents read before coding: ``` backend-patterns.md react-frontend.md vue-frontend.md testing-patterns.md monorepo-structure.md error-handling.md critical-rules.md playwright-testing.md react-animations.md adding-packages.md ``` ### Structured Task System Auto-detects difficulty. Simple tasks: inline. Hard tasks: parallel agents. ``` docs/tasks/user-settings/ ├── README.md # PRD ├── ARCHITECTURE.md # Contracts between phases ├── CONTEXT.md # Current state, resumable ├── 01-models.md # Phase with file:line refs └── 02-api.md ``` ## Testing **80/15/5 rule:** Contract tests (API, bot) → Business logic → Regression. | Package | Purpose | |---------|---------| | testcontainers | Real PostgreSQL, not SQLite | | pytest-xdist | Parallel execution | | pytest-testmon | Incremental (only changed code) | | inline-snapshot | Snapshot assertions | | respx | HTTP mocking (LLM, payments) | ```bash make test APP=myapp # Full parallel suite make test-quick APP=myapp # Incremental — sub-second feedback ``` Each test runs in isolated transaction with automatic rollback. ## Commands Reference All make commands require `APP=<name>`: ```bash # Docker make up APP=template-vue # Start services make down APP=template-vue # Stop services make logs APP=template-vue # View logs make shell-webhook APP=template-vue # Backend shell # Backend make test APP=template-vue # Run tests make lint APP=template-vue # Ruff + type checks make migration msg="..." APP=template-vue # Create migration make upgrade APP=template-vue # Apply migrations make schema APP=template-vue # Generate TypeScript types # Frontend cd apps/template-vue/frontend pnpm dev # Dev server pnpm build # Production build pnpm typecheck # Type checking ``` ## Project Structure ``` gramkit/ ├── .claude/ │ ├── commands/ # Slash commands │ ├── skills/ # Auto-invoked procedures │ ├── agents/ # Subagents (developer, testing) │ └── shared/ # Pattern docs ├── core/ │ ├── backend/ # Shared Python (FastAPI, SQLAlchemy) │ ├── frontend/ # Shared Vue.js components │ └── frontend-react/ # Shared React components ├── apps/ │ ├── template-vue/ # Vue.js template │ └── template-react/ # React/Next.js template ├── docs/ # Documentation ├── nginx/ # Gateway configuration └── Makefile # Unified commands ``` ## Requirements - Docker & Docker Compose - Node.js 20+ & pnpm - Python 3.14+ - Make **Optional:** - Telegram Bot Token (from @BotFather) - Cloudflare Tunnel (for TMA testing) ## Why gramkit? - **Not a tutorial** — Production patterns from real apps shipping to users - **Type-safe end-to-end** — Change backend, frontend types update automatically - **Monorepo done right** — Shared core without dependency hell - **Escape hatches** — Every feature can be disabled or swapped - **Claude Code native** — Orchestration architecture for AI-assisted development - **Two frameworks** — Same patterns in Vue and React, pick your preference ## Contributing 1. Fork the repository 2. Create a branch: `git checkout -b feature/your-feature` 3. Make changes and test: `make test APP=template-vue` 4. Commit: `git commit -m "feat: your feature"` 5. Push and open a Pull Request ## License MIT — See [LICENSE](LICENSE)
看看同类模板
对比同技术栈与用途的模板,找到更适合的视觉与内容结构。

ai-website-cloner-template
Clone any website with one command using AI coding agents
Next.js · 启动器

Next.js SaaS Starter
Next.js SaaS Starter 是 Next.js 官方维护的 SaaS 起点模板,定位介于学习资源和可直接部署的脚手架之间。
Next.js · SaaS

Next.js Commerce
Next.js Commerce 是 Vercel 团队维护的电商启动模板,基于 Next.js App Router 构建,采用服务端渲染、React Server Components、Server Actions …
Next.js · 电商

Next-js-Boilerplate
Next-js-Boilerplate 是一个面向 Next.js 16、Tailwind CSS 4 和 TypeScript 的启动器,核心定位是开发者体验优先。
Next.js · 启动器

tailwind-nextjs-starter-blog
tailwind-nextjs-starter-blog 是一个面向个人技术博客的 Next.js 与 Tailwind CSS 启动模板,其 v2 版本基于 App Router 与 React Server Comp…
Next.js · 博客

next-forge
Production-grade Turborepo template for Next.js apps.
Next.js · 启动器
