bun-monorepo-vite-elysia-spa
Scaffold or regenerate a Bun fullstack monorepo using official generators only: bun create elysia@latest for backend and bun create vite@latest --template react-ts for SPA frontend, then apply core backend wiring (Better Auth, Drizzle, MCP, OpenAPI, CORS, and security defaults). Use when creating or resetting a Bun workspace monorepo to latest generator versions.
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o bun-monorepo-vite-elysia-spa.zip https://jpskill.com/download/10665.zip && unzip -o bun-monorepo-vite-elysia-spa.zip && rm bun-monorepo-vite-elysia-spa.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/10665.zip -OutFile "$d\bun-monorepo-vite-elysia-spa.zip"; Expand-Archive "$d\bun-monorepo-vite-elysia-spa.zip" -DestinationPath $d -Force; ri "$d\bun-monorepo-vite-elysia-spa.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
bun-monorepo-vite-elysia-spa.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
bun-monorepo-vite-elysia-spaフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
📖 Claude が読む原文 SKILL.md(中身を展開)
この本文は AI(Claude)が読むための原文(英語または中国語)です。日本語訳は順次追加中。
Bun Workspace Vite Elysia SPA
Overview
Create a Bun workspace monorepo with latest generator output, not manual scaffolding. Use official generators first, then apply backend wiring and security defaults.
Required Workflow
- Confirm target path and whether existing
apps/backendorapps/frontendshould be replaced. - Run official generators only:
bun create elysia@latest apps/backendbun create vite@latest apps/frontend --template react-ts
- Install required backend dependencies and dev dependencies with Bun.
- Apply backend wiring using
references/elysia-core-backend-reference.md(copied fromelysia-core-backend) for Better Auth, Drizzle, Postgres, MCP endpoint, OpenAPI docs, CORS allowlist, CSRF middleware, and security headers. - Keep frontend as SPA (Vite React TS) unless explicitly requested otherwise.
- Wire root Bun workspace scripts using Bun filters (
bun run --filter "*" <script>). - Provide run steps and env vars required for local development.
Hard Rules
- Do not hand-roll generated app baselines when Bun is available.
- Do not keep stale/legacy package versions from old manual scaffolds.
- Do not clobber existing apps without explicit confirmation.
- Prefer replacing app folders (
apps/backend,apps/frontend) over patching old generated output when user asks for latest versions.
Backend Wiring Checklist
- Better Auth mounted and configured with Drizzle adapter.
- Drizzle schema and config present.
- Postgres connection via env
DATABASE_URL. - MCP plugin wired through
elysia-mcp(not rawMcpServerplugin use). - OpenAPI docs route enabled.
- CORS allowlist bound to frontend origin env.
- CSRF protection on non-auth cookie-based mutation routes.
- Security headers middleware enabled.
Frontend SPA Checklist
- React + TypeScript Vite template.
vitescripts present (dev,build,preview) withdevbinding host for LAN/WSL access.- Simple SPA entrypoint validated.
Run and Verify
bun install- Run all workspaces:
bun run --filter "*" dev - Run one workspace:
bun run --filter frontend devorbun run --filter backend dev - Frontend default port:
3000. Backend default port:8000. - For frontend direct run, use
bun run dev --host 0.0.0.0 --port 3000. - For backend direct run, ensure
src/index.tslistens on8000. bun run db:generateandbun run db:migratein backend when DB is configured.
References
- Read
references/workflow.mdfor exact commands, package lists, and file expectations. - For any backend work, read
references/elysia-core-backend-reference.mdfirst (copied fromelysia-core-backend). - Upstream reference implementation:
ahmed-lotfy-dev/elysia-core-backend.