A simple fullstack authentication system using Angular, Node.js, Express, TypeScript, MySQL, and JWT.
-
Register and Login
-
JWT Authentication
-
Protected Profile API
-
Angular frontend + Express backend
-
MySQL database
-
Password hashing with bcrypt
-
Frontend: Angular, TypeScript
-
Backend: Node.js, Express, TypeScript
-
Database: MySQL
-
Auth: JWT, bcrypt
cd backend
npm install
npm run dev
PORT=3001
DB_HOST=localhost
DB_USER=root
DB_PASSWORD=yourpassword
DB_NAME=login_system
JWT_SECRET=your_secret
cd frontend
npm install
ng serve
- Frontend: http://localhost:4200
- Backend: http://localhost:3001
POST /api/auth/register
POST /api/auth/login
GET /api/auth/profile
Authorization: Bearer TOKEN
Punnathorn Musikphan
https://github.com/PunTwT