A small server-rendered task manager: register, log in, create tasks with priority/status/deadline, filter them, and check a weather widget for your city on the dashboard.
Features · Screenshots · Getting started · Architecture · API · Contributing
| Login | Dashboard with stats & weather |
| Task list with filters | Create / edit task |
- Email + password authentication (
bcryptjshashing, session-based) - Create, edit, delete and filter tasks by status and priority
- Toggle a task between
activeandcompletedwith one click - Per-user profile (name, city) — city drives the dashboard weather widget
- Live weather for your city via the OpenWeather API, loaded client-side with a graceful fallback if the key/city is missing
- Server-rendered pages (EJS) with a small Bootstrap-based UI, no build step
graph TD
Browser -->|HTTP| Express[Express App]
Express --> Session[express-session]
Session --> AuthMW[Auth middleware]
AuthMW --> Routes{Routes}
Routes --> AuthR[auth.js]
Routes --> DashR[dashboard.js]
Routes --> TaskR[task.js]
Routes --> ProfileR[profile.js]
Routes --> ApiR[api.js]
AuthR --> UserModel[(userModel)]
DashR --> UserModel
DashR --> TaskModel[(taskModel)]
TaskR --> TaskModel
ProfileR --> UserModel
ApiR --> Weather[weatherService]
UserModel --> MySQL[(MySQL)]
TaskModel --> MySQL
Weather --> OWM[OpenWeather API]
Full breakdown of layers, the auth sequence, task lifecycle and DB schema lives in docs/ARCHITECTURE.md.
- Node.js and npm
- A running MySQL server
- An OpenWeather API key (free tier works) if you want the weather widget to actually return data
git clone https://github.com/arturrw/Task-Tracker.git
cd Task-Tracker
npm installLog in to MySQL as a user allowed to create databases/users, then run the provided schema:
mysql -u root -p < sql/schema.sqlThis creates the task_tracker_db database, a tt_user MySQL user, and the users/tasks tables.
The schema ships with a placeholder password (
strong_password_here) fortt_user. Change it insql/schema.sqlbefore running it, and use the same value in.env.
Copy the example file and fill in your own values:
cp .env.example .env| Variable | Description |
|---|---|
PORT |
Port the server listens on (default 3000) |
DB_HOST, DB_USER, DB_PASSWORD, DB_NAME |
MySQL connection details |
SESSION_SECRET |
Random string used to sign the session cookie |
WEATHER_API_KEY |
Your OpenWeather API key |
WEATHER_API_BASE_URL |
OpenWeather endpoint (defaults to the current-weather API) |
.env is git-ignored — never commit real secrets in it.
npm startThen open http://localhost:3000. You'll be redirected to /login until you register an account.
The app is mostly server-rendered pages, plus one JSON endpoint (GET /api/weather) used by the dashboard. Full request/response shapes and the full route table are in docs/API.md.
Bug reports, small fixes and feature ideas are welcome. See docs/CONTRIBUTING.md for branch naming, code style and how to test your change locally before opening a PR.
MIT © arturrw