How mhmdhammoud702/tasks works
The repository contains several small browser exercises and a client/server user manager. Task 1 manages users locally; Task 2 explores country data from an external API. Task 5 provides authenticated user CRUD with database persistence and a cached user list. The sampled source establishes those flows, but Task 3 and Task 4 have no sampled behavior, so they are represented only as pages. No README was present to clarify their intended capabilities.
Main entry points: app.js Express app · index.js Country search and view · users.controller.js User operations · users.route.js User endpoints
Components 21
Local User Manager
- User form and table
Task 1/index.js - Browser storage
Country Explorer
- Country search and view
Task 2/index.js - Countries API
- Saved favorites
User Management Service
- User manager UI
Task 5/frontend/index.js - Express app
Task 5/backend/src/app.js - Token endpoint
Task 5/backend/src/routes/auth.route.js - Token issuance
Task 5/backend/src/controllers/auth.controller.js - JWT signing
Task 5/backend/src/config/jwt.js - Route protection
Task 5/backend/middleware/auth.middleware.js - User endpoints
Task 5/backend/src/routes/users.route.js - User operations
Task 5/backend/src/controllers/users.controller.js - User model
Task 5/backend/src/models/Users.js - MongoDB
- Database connection
Task 5/backend/src/config/db.js - Cache client
Task 5/backend/src/config/memcached.js - Memcached
Other Task Pages
- Task 3 page
Task 3/index.html - Task 4 page
Task 4/index.html
Other components
- Browser user
Connections 22
- Browser user → User form and table: uses
- User form and table → Browser storage: reads and writes
- Browser user → Country search and view: uses
- Country search and view → Countries API: fetches data
- Country search and view → Saved favorites: reads and writes
- Browser user → User manager UI: uses
- User manager UI → Express app: sends requests
- Express app → Database connection: connects
- Database connection → MongoDB: connects
- Express app → Token endpoint: dispatches
- Token endpoint → Token issuance: dispatches
- Token issuance → JWT signing: issues token
- Express app → Route protection: guards users route
- Route protection → User endpoints: allows request
- Express app → User endpoints: dispatches
- User endpoints → User operations: dispatches
- User operations → User model: queries and updates
- User model → MongoDB: persists users
- User operations → Cache client: reads and invalidates
- Cache client → Memcached: accesses
- Browser user → Task 3 page: opens
- Browser user → Task 4 page: opens