A todo app with a built-in focus timer. React + Vite frontend, Express + MongoDB backend.
- Create todos (title + description)
- View all todos
- Mark todos as done
- Delete todos
- Focus page with timer and ambient audio
- Frontend: React 19, Vite, React Router, Axios, Framer Motion
- Backend: Node.js, Express 5, Mongoose, Zod, CORS, dotenv
cd backend
npm installCreate backend/.env:
PORT=3000
MONGO_DB_URL=<your MongoDB connection string>
Run: node index.js
cd frontend
npm install
npm run devRuns at http://localhost:5173 (the only origin allowed by backend CORS).
| Method | Route | Description |
|---|---|---|
| POST | /todo |
Create a todo |
| GET | /todos |
List all todos |
| PUT | /completed/:id |
Mark a todo as completed |
| DELETE | /delete/:id |
Delete a todo |
backend/ Express server, Mongoose model, Zod schemas
frontend/ React app (Pages, Components, Services)