An end-to-end e‑learning platform with course management, quizzes, certificates, enrollment and progress tracking, discussion forums, and a modern, responsive UI. The project is a monorepo with a React client and an Express/MongoDB server.
- Overview
- Features
- Tech Stack
- Repository Structure
- Getting Started
- Environment Variables
- Running Locally
- Build & Production
- API Overview
- Security & Performance
- Deployment
- Contributing
- License
This platform enables admins to create and manage courses, quizzes, and content; and empowers learners with a rich course player, interactive quizzes, discussion forums, and downloadable certificates upon completion. Refer to ENHANCED_FEATURES.md for a comprehensive description of the latest functionality and data models.
-
Admin
- Login/Signup
- Manage users
- Add blogs/articles
- Add video courses
- Add and manage certification test questions
- Logout
-
User
- Login/Signup
- Profile and learning dashboard
- Read blogs/articles
- Run in‑browser code editor
- Take paid certification tests
- Download completion certificates
- Logout
Additional highlights (see ENHANCED_FEATURES.md for details):
- Enrollment with detailed lesson progress, notes, and analytics
- Advanced quiz system (MCQ, true/false, fill-in-the-blank, essay), time limits, attempts, scoring
- Certificate generation with unique IDs, QR/verification code, and PDF export
- Course-specific discussion forums with moderation tools and engagement metrics
- Modern, responsive UI/UX with improved navigation and accessibility
-
Client
- React 18 (Create React App)
- React Router v6
- Bootstrap 5, Tailwind CSS (utility-first styling)
- Axios, React Icons, React Bootstrap, Headless UI
- Ace Editor integrations (
react-ace,ace-builds) - PDF/Canvas utils (
jspdf,html2canvas)
-
Server
- Node.js, Express
- MongoDB, Mongoose
- JWT authentication
- Multer (uploads), Nodemailer (email), Express Validator
- Google OAuth 2.0 (
passport,passport-google-oauth20) - CORS, dotenv
-
Deployment
- Client: Vercel
- Server: Render.com
- Database: MongoDB Atlas
Elearning/
├── client/ # React SPA (Create React App)
│ ├── src/
│ ├── public/
│ ├── package.json # CRA scripts: start, build, test, eject
│ └── tailwind.config.js
└── server/ # Express API
├── controllers/
├── routes/
├── models/
├── middleware/
├── util/
├── app.js # Server entrypoint
└── package.json # scripts: start (nodemon), build
- Node.js 16+
- npm or yarn
- MongoDB (local or Atlas)
- Client
cd client && npm install
- Server
cd server && npm install
Create .env files for both client and server. The following keys are used across the project:
-
Client (
client/.env)REACT_APP_API_URL=https://your-server-url.com
-
Server (
server/.env)DB_URL=your-mongodb-connection-stringJWT_SECRET=your-jwt-secretGOOGLE_CLIENT_ID=your-google-client-idGOOGLE_CLIENT_SECRET=your-google-client-secretGOOGLE_CALLBACK_URL=https://your-server-url.com/auth/google/callbackCLIENT_URL=https://your-client-url.com
If you use email features, add your SMTP provider config (e.g., SMTP_HOST, SMTP_PORT, SMTP_USER, SMTP_PASS).
Open two terminals:
- Server
cd server
npm start
- Client
cd client
npm start
The React dev server (port 3000) should point to your API via REACT_APP_API_URL.
- Client
cd client
npm run build
- Server
cd server
npm run build
Note: The server build script runs node app.js. For production hosting, run with a process manager (e.g., PM2) or your platform’s run command.
Selected endpoints (see ENHANCED_FEATURES.md for full list):
-
Auth
POST /auth/signupPOST /auth/loginGET /auth/googleGET /auth/google/callback
-
Courses
GET /coursesGET /courses/:idPOST /courses(admin)PUT /courses/:id(admin)DELETE /courses/:id(admin)
-
Enrollment
POST /enrollment/enrollGET /enrollment/my-enrollmentsPATCH /enrollment/:id/lesson/:moduleId/:lessonIdPOST /enrollment/:id/rateGET /enrollment/:courseId/analytics
-
Certificates
POST /certificates/generateGET /certificates/:idGET /certificates/verify/:code
-
Quizzes
POST /quizzesGET /quizzes/course/:courseIdPOST /quizzes/:id/submitGET /quizzes/:id/results
-
Discussions
POST /discussionsGET /discussions/course/:courseIdPOST /discussions/:id/commentsPUT /discussions/:id
- Security: JWT auth, input validation/sanitization, CORS config, rate limiting (recommended), secrets via env vars
- Performance: DB indexing, optimized queries, client lazy loading and code splitting, image optimization and caching
-
Client (Vercel)
- Connect the
client/directory to Vercel - Configure
REACT_APP_API_URLin Vercel project settings - Automatic deploys on push
- Connect the
-
Server (Render.com)
- Connect the
server/directory to Render - Configure environment variables (
DB_URL,JWT_SECRET, Google OAuth,CLIENT_URL) - Use MongoDB Atlas
- Automatic deploys on push
- Connect the
- Fork the repository
- Create a feature branch
- Make changes and add tests where appropriate
- Open a pull request with a clear description
MIT
- Open an issue in this repository with steps to reproduce and logs where relevant
- See
ENHANCED_FEATURES.mdfor more technical detail
Last updated: September 2025

