A responsive Dynamic Angular Dashboard with user authentication, API integration, state management using Angular Signals, and performance optimizations.
Live Demo - Angular Dashboard.
- User Authentication → JWT-based login & logout
- Dynamic Data Table → Fetches data from JSONPlaceholder
- Filter/Search, Sorting, Pagination → Built with Angular Material Table
- State Management → Uses Angular Signals
- Lazy Loading & Performance Optimizations → Uses OnPush Change Detection and async pipe
- Dark Mode Toggle
- Auth Unit Test
git clone https://github.com/chiragobhan/dynamic-angular-dashboard.git
cd dynamic-angular-dashboard
npm install
We use json-server
to simulate an API for user authentication. Users are stored in db.json
:
{
"users": [
{ "id": 1, "username": "admin", "password": "password", "token": "mock-jwt-token" },
{ "id": 2, "username": "testuser", "password": "test123", "token": "mock-jwt-token" }
]
}
npx json-server --watch db.json --port 3000
ng serve
Then open http://localhost:4200/
in your browser.
- Users login via
json-server
API (Mock backend) - JWT token is stored in
localStorage
AuthGuard
protects routes, and prevents logged-out users from accessing/dashboard
- Angular Signals manage authentication state
- Reactive
signal()
ensures instant UI updates on login/logout
- The dashboard content is lazy-loaded and uses OnPush Change Detection
- API requests are optimized via Angular’s
async pipe
- Pagination, Sorting, and Filtering happen on the frontend for better UX
- Uses
localStorage
to persist user theme - Applied via
document.body.classList.toggle('dark-theme')
To run unit tests:
ng test
This will open the Karma test runner and execute auth unit test.




Disclaimer: This project is an assignment completed for Pillway. All logos and branding elements belong to Pillway and are used solely for demonstration purposes.