# creepahh/task-manager architecture

> Architecture diagram of the GitHub repository creepahh/task-manager, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/creepahh/task-manager
- Repository: https://github.com/creepahh/task-manager

## Overview

Task Manager is a React client backed by an Express API and MySQL. Users register or sign in, then use the dashboard to list, create, edit, and delete their personal tasks; task endpoints verify JWTs and scope operations to the authenticated user. The graph covers the documented authentication and CRUD capabilities. Relationships are based on the sampled source and README endpoint documentation; unsampled modules are not assumed to participate.

Main entry points: [`client/src/services/api.js`](https://github.com/creepahh/task-manager/blob/main/client/src/services/api.js) (API client), [`client/src/App.js`](https://github.com/creepahh/task-manager/blob/main/client/src/App.js) (App and routing), [`server/routes/task.js`](https://github.com/creepahh/task-manager/blob/main/server/routes/task.js) (Task routes), [`server/config/db.js`](https://github.com/creepahh/task-manager/blob/main/server/config/db.js) (Database connection)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["React client"]
  node_app["App and routing<br/>[App.js]"]
  node_login["Login<br/>[Login.js]"]
  node_register["Registration<br/>[Register.js]"]
  node_dashboard["Task dashboard<br/>[Dashboard.js]"]
  node_http_client["API client<br/>[api.js]"]
end

subgraph group_api["Express API"]
  node_server["Express app<br/>[index.js]"]
  node_auth_routes["Authentication routes<br/>[auth.js]"]
  node_task_routes["Task routes<br/>[task.js]"]
  node_jwt["JWT verification<br/>[jwt.js]"]
end

subgraph group_domain["Domain and persistence"]
  node_user_model["User model<br/>[User.js]"]
  node_task_model["Task model<br/>[Task.js]"]
  node_db_config["Database connection<br/>[db.js]"]
end

node_user(("User"))
node_mysql[("MySQL")]

node_user -->|"uses"| node_app
node_app -->|"routes to"| node_login
node_app -->|"routes to"| node_register
node_app -->|"routes to"| node_dashboard
node_login -->|"calls"| node_http_client
node_register -->|"calls"| node_http_client
node_dashboard -->|"calls"| node_http_client
node_http_client -->|"HTTP requests"| node_auth_routes
node_http_client -->|"HTTP requests"| node_task_routes
node_server -->|"mounts"| node_auth_routes
node_server -->|"mounts"| node_task_routes
node_server -->|"syncs database"| node_db_config
node_auth_routes -->|"queries"| node_user_model
node_task_routes -->|"verifies token"| node_jwt
node_task_routes -->|"queries"| node_task_model
node_task_model -->|"associates with"| node_user_model
node_user_model -->|"defines model"| node_db_config
node_task_model -->|"defines model"| node_db_config
node_db_config -->|"connects to"| node_mysql

click node_app "https://github.com/creepahh/task-manager/blob/main/client/src/App.js"
click node_login "https://github.com/creepahh/task-manager/blob/main/client/src/components/Login.js"
click node_register "https://github.com/creepahh/task-manager/blob/main/client/src/components/Register.js"
click node_dashboard "https://github.com/creepahh/task-manager/blob/main/client/src/components/Dashboard.js"
click node_http_client "https://github.com/creepahh/task-manager/blob/main/client/src/services/api.js"
click node_server "https://github.com/creepahh/task-manager/blob/main/server/index.js"
click node_auth_routes "https://github.com/creepahh/task-manager/blob/main/server/routes/auth.js"
click node_task_routes "https://github.com/creepahh/task-manager/blob/main/server/routes/task.js"
click node_jwt "https://github.com/creepahh/task-manager/blob/main/server/middleware/jwt.js"
click node_user_model "https://github.com/creepahh/task-manager/blob/main/server/models/User.js"
click node_task_model "https://github.com/creepahh/task-manager/blob/main/server/models/Task.js"
click node_db_config "https://github.com/creepahh/task-manager/blob/main/server/config/db.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_login,node_register,node_dashboard,node_http_client,node_user toneBlue
class node_server,node_auth_routes,node_task_routes,node_jwt,node_mysql toneAmber
class node_user_model,node_task_model,node_db_config toneMint
```

## Components

### React client

- [App and routing](https://github.com/creepahh/task-manager/blob/main/client/src/App.js): `client/src/App.js`
- [Login](https://github.com/creepahh/task-manager/blob/main/client/src/components/Login.js): `client/src/components/Login.js`
- [Registration](https://github.com/creepahh/task-manager/blob/main/client/src/components/Register.js): `client/src/components/Register.js`
- [Task dashboard](https://github.com/creepahh/task-manager/blob/main/client/src/components/Dashboard.js): `client/src/components/Dashboard.js`
- [API client](https://github.com/creepahh/task-manager/blob/main/client/src/services/api.js): `client/src/services/api.js`

### Express API

- [Express app](https://github.com/creepahh/task-manager/blob/main/server/index.js): `server/index.js`
- [Authentication routes](https://github.com/creepahh/task-manager/blob/main/server/routes/auth.js): `server/routes/auth.js`
- [Task routes](https://github.com/creepahh/task-manager/blob/main/server/routes/task.js): `server/routes/task.js`
- [JWT verification](https://github.com/creepahh/task-manager/blob/main/server/middleware/jwt.js): `server/middleware/jwt.js`

### Domain and persistence

- [User model](https://github.com/creepahh/task-manager/blob/main/server/models/User.js): `server/models/User.js`
- [Task model](https://github.com/creepahh/task-manager/blob/main/server/models/Task.js): `server/models/Task.js`
- [Database connection](https://github.com/creepahh/task-manager/blob/main/server/config/db.js): `server/config/db.js`

### Other components

- **User**
- **MySQL**

## Connections

- User → App and routing: uses (evidence: `README.md`)
- App and routing → Login: routes to (evidence: `client/src/App.js`)
- App and routing → Registration: routes to (evidence: `client/src/App.js`)
- App and routing → Task dashboard: routes to (evidence: `client/src/App.js`)
- Login → API client: calls (evidence: `client/src/components/Login.js`)
- Registration → API client: calls (evidence: `client/src/components/Register.js`)
- Task dashboard → API client: calls (evidence: `client/src/components/Dashboard.js`)
- API client → Authentication routes: HTTP requests (evidence: `README.md`)
- API client → Task routes: HTTP requests (evidence: `README.md`)
- Express app → Authentication routes: mounts (evidence: `server/index.js`)
- Express app → Task routes: mounts (evidence: `server/index.js`)
- Express app → Database connection: syncs database (evidence: `server/index.js`)
- Authentication routes → User model: queries (evidence: `server/routes/auth.js`)
- Task routes → JWT verification: verifies token (evidence: `server/routes/task.js`)
- Task routes → Task model: queries (evidence: `server/routes/task.js`)
- Task model → User model: associates with (evidence: `server/models/Task.js`)
- User model → Database connection: defines model (evidence: `server/models/User.js`)
- Task model → Database connection: defines model (evidence: `server/models/Task.js`)
- Database connection → MySQL: connects to (evidence: `server/config/db.js`)
