Step 30 of 30
Build and ship a task manager with Vue 3, Elysia, MongoDB, JWT auth, tests, and Docker deployment
Workshop: TaskFlow — fullstack task manager ครบทุกอย่างที่เรียนมา (auth, CRUD, tests, Docker)
Build and ship TaskFlow, a fullstack task management app: Vue 3 frontend, Elysia API, MongoDB persistence, JWT auth — running on Bun, tested, and deployable with Docker.
This workshop uses everything from the path. There is no starter code; every decision is yours.
title (1–200 chars), priority (low | high), optional dueDate?priority=/login — login + signup forms with client validation (Zod), field-level errors/ — task list: add form, filter tabs, complete/delete actions, empty and loading states/login with a redirect query, and sends them back after loginlocalStorageDesign the schema yourself. Minimum shape:
users { email (unique), passwordHash, name }
tasks { title, priority, dueDate, completed, user (ref → users), timestamps }
Justify one embed-vs-reference decision in your README (e.g., why user is a reference, not embedded).
Define with t.Schema — validation and response types are required:
| Method | Path | Auth | Notes |
|---|---|---|---|
| POST | /auth/signup | no | 201 + token |
| POST | /auth/login | no | 200 + token, or 401 |
| GET | /tasks | yes | mine only, ?priority= |
| POST | /tasks | yes | 201, 422 on invalid |
| PATCH | /tasks/:id | yes | complete/reopen; 404 if not mine |
| DELETE | /tasks/:id | yes | 404 if not mine |
Error responses share one shape: { error: { code, message } }.
server/ — Elysia app as route modules + plugins (auth derive, repos via decorate), MongoDB singleton in db.ts, config validated at startup in env.tsfrontend/ — Treaty client typed against type App, composables per domain (useTasks), components small and prop-driven/api proxy in productionbun test API suite covering validation, auth (401), and ownership (user A cannot read user B's task — expect 404)server/ and frontend/; Mongo via Compose; GET /tasks returns a fixture → verify: both dev servers running, one endpoint round-triponError, form validation both sides, loading/empty/error UI states → verify: invalid input shows field errors; API returns clean 422sbun test green, including the ownership test/api proxy and history fallback, root Compose file → verify: docker compose up --build gives a working app on :80server/ + frontend/, both starting with one command eachbun test, component tests optional)docker compose up --build serving the full app.env.example committed), your embed-vs-reference justification, what you would build nextany on the API boundarydocker compose up --build → working appPrevious
Deployment with Docker
Final step