A professional admin dashboard built with React, TypeScript, and Vite.
- React 19 with Vite
- TypeScript (strict mode)
- React Router DOM for client-side routing
- TanStack Query for async state management
- Axios for HTTP requests
- CSS Modules for scoped styling
- ESLint + Prettier for code quality
- Node.js >= 18
- npm >= 9
npm installCopy the example env file and adjust values as needed:
cp .env.example .envnpm run devOpen http://localhost:5173 in your browser.
npm run buildnpm run preview| Script | Description |
|---|---|
npm run dev |
Start the development server |
npm run build |
Build for production |
npm run lint |
Run ESLint |
npm run lint:fix |
Run ESLint with auto-fix |
npm run format |
Format code with Prettier |
npm run preview |
Preview the production build |
src/
├── app/
│ ├── providers/ # Context providers (QueryClient)
│ └── router/ # Route config and constants
├── components/
│ ├── layout/ # Sidebar, Topbar, DashboardLayout
│ └── ui/ # Reusable UI components
├── features/
│ ├── auth/ # Authentication feature
│ ├── dashboard/ # Dashboard feature
│ └── users/ # Users management feature
├── hooks/ # Custom React hooks
├── services/ # API client and services
├── styles/ # Global styles and CSS variables
├── types/ # Shared TypeScript types
└── utils/ # Utility functions
| Path | Page |
|---|---|
/login |
Login |
/dashboard |
Dashboard |
/users |
Users |
Private