This is a full-stack LMS application similar to Udemy, built with Node.js, Prisma, TypeScript, Express, and React. It includes authentication, course management, enrollments, lectures, progress tracking, and purchases.
- Node.js with Express.js (API development)
- Prisma (ORM for PostgreSQL)
- JWT Authentication (Access & Refresh tokens)
- Rate Limiting (Prevents abuse on auth routes)
- Swagger (API Documentation)
- Docker & Docker Compose (Database containerization)
- React + TypeScript (Component-based UI)
- Redux Toolkit (State management)
- Material UI & Framer Motion (UI & animations)
- Axios (API requests)
- Toastify (Notifications)
- User Authentication: Signup, Login, Logout, Refresh Token
- Course Management: CRUD operations for courses
- Lecture System: Add lectures to courses
- Progress Tracking: Track completion of lectures
- Enrollment System: Users can enroll in courses
- Purchases: Secure course purchases with tracking
- Rate Limiting: Protects API from excessive requests
- Clone the repository:
git clone https://github.com/aman75way/LMS cd LMS
- Install dependencies:
npm install
- Configure environment variables:
cp .env.example .env
- Start PostgreSQL using Docker:
docker-compose up -d
- Apply database migrations:
npx prisma migrate dev --name init
- Start the backend server:
npm run dev
- Navigate to the frontend folder:
cd frontend
- Install dependencies:
npm install
- Start the React app:
npm run dev
Swagger API documentation is available at:
http://localhost:5000/api-docs
Variable | Description |
---|---|
PORT |
Server port (default: 5000) |
DATABASE_URL |
PostgreSQL connection URL |
JWT_SECRET |
Secret key for JWT |
FRONTEND_URL |
Frontend base URL (CORS) |
lms-api/
├── backend/
│ ├── app/
│ │ ├── auth/ # Authentication module
│ │ ├── course/ # Course management
│ │ ├── enrollment/ # Enrollment system
│ │ ├── lecture/ # Lecture system
│ │ ├── progress/ # Progress tracking
│ │ ├── purchase/ # Course purchases
│ │ ├── common/ # Middleware & utilities
│ ├── prisma/ # Prisma schema
│ ├── docker-compose.yml
│ ├── index.ts # Server entry point
├── frontend/
│ ├── src/
│ │ ├── components/
│ │ ├── pages/
│ │ ├── store/
│ ├── public/
│ ├── index.tsx