This is a simple Angular application built as an assignment to demonstrate core Angular concepts including components, routing, directives, dynamic components, and API integration. The app fetches users from an API, displays them in a clean UI, and opens a dynamic user details modal.
- Fetches data from JSONPlaceholder API.
- Displays a vertically aligned list of users.
- Each user card shows:
- Name (bold)
- Email (light text)
- “View Details” button on the right.
- Clicking “View Details” opens a dynamic modal.
- The modal is not statically added in HTML.
- Loaded using ViewContainerRef + createComponent() (as required).
- Shows selected user information: Name, Email, Username, Phone.
- Close button removes the modal.
- Modal route syncs with URL:
/users/:id.
/users→ Shows list of users./users/:id→ Shows list + auto-opens modal for that user./about→ Simple About page.''→ Redirects to/users.**→ Redirects to/users.
- Uses Angular HttpClient.
- UserService handles all requests.
- Includes loading & error handling.
- Angular 16.2.11 (or your version)
- TypeScript
- HTML + CSS
- JSONPlaceholder API
git bash:
- git clone https://github.com/jiya2802/Angular-users-app.git
- cd Angular-users-app
npm install
ng serve
| Requirement | Status |
|---|---|
| Users list | ✔ Completed |
| View Details popup | ✔ Dynamic Component |
| Routing (/users, /user/:id) | ✔ Implemented as /users/:id |
| API calls | ✔ Handled |
| Directives | ✔ Used (*ngFor, *ngIf, [ngStyle]) |
| Clean UI | ✔ Done |
| README with setup + description | ✔ Provided |


