Skip to content

Sagar-6203620715/Coursify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

63 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Course Comparator

A modern, responsive web application for comparing and discovering online courses across different domains and platforms.

πŸš€ Features

Core Features

  • Course Discovery: Browse courses by domains, sections, and categories
  • Advanced Filtering: Sort courses by price, duration, rating, and more
  • Real-time Chat: Discuss courses with other users in domain-specific chat rooms
  • Course Ratings & Reviews: Rate and review courses with detailed feedback
  • Responsive Design: Fully responsive design that works on all devices
  • Admin Panel: Comprehensive admin interface for managing content

User Features

  • User Authentication: Secure login/register system with JWT
  • Course Comparison: Compare courses side-by-side
  • Affiliate Integration: Direct links to course platforms
  • Search Functionality: Advanced search with filters
  • Mobile-First Design: Optimized for mobile and tablet devices

Admin Features

  • User Management: Manage user accounts and permissions
  • Course Management: Add, edit, and delete courses
  • Domain Management: Organize courses by domains
  • Section Management: Categorize domains into sections
  • Content Moderation: Moderate reviews and discussions

πŸ› οΈ Tech Stack

Frontend

  • React 19 - Modern React with latest features
  • Vite - Fast build tool and development server
  • Tailwind CSS - Utility-first CSS framework
  • Redux Toolkit - State management
  • React Router - Client-side routing
  • React Icons - Icon library
  • Axios - HTTP client
  • Socket.io Client - Real-time communication
  • Swiper - Touch slider component

Backend

  • Node.js - JavaScript runtime
  • Express.js - Web framework
  • MongoDB - NoSQL database
  • Mongoose - MongoDB object modeling
  • JWT - Authentication
  • Socket.io - Real-time communication
  • Cloudinary - Image upload and management
  • Multer - File upload handling
  • bcryptjs - Password hashing
  • Helmet - Security middleware
  • CORS - Cross-origin resource sharing

πŸ“¦ Installation

Prerequisites

  • Node.js (v18 or higher)
  • npm (v9 or higher)
  • MongoDB (local or cloud instance)

Backend Setup

  1. Clone the repository

    git clone <repository-url>
    cd course_comparator
  2. Install backend dependencies

    cd backend
    npm install
  3. Environment Configuration Create a .env file in the backend directory:

    PORT=5000
    MONGO_URI=your_mongodb_connection_string
    JWT_SECRET=your_jwt_secret_key
    CLOUDINARY_CLOUD_NAME=your_cloudinary_cloud_name
    CLOUDINARY_API_KEY=your_cloudinary_api_key
    CLOUDINARY_API_SECRET=your_cloudinary_api_secret
    NODE_ENV=development
  4. Start the backend server

    npm run dev

Frontend Setup

  1. Install frontend dependencies

    cd frontend
    npm install
  2. Environment Configuration Create a .env file in the frontend directory:

    VITE_BACKEND_URL=http://localhost:5000
  3. Start the frontend development server

    npm run dev

πŸ—„οΈ Database Setup

Initial Data Seeding

cd backend
npm run seed

Create Admin User

cd backend
npm run make-admin

πŸš€ Development

Available Scripts

Backend

  • npm run dev - Start development server with nodemon
  • npm start - Start production server
  • npm run seed - Seed database with initial data
  • npm run make-admin - Create admin user
  • npm test - Run tests
  • npm run lint - Lint code
  • npm run format - Format code

Frontend

  • npm run dev - Start development server
  • npm run build - Build for production
  • npm run preview - Preview production build
  • npm test - Run tests
  • npm run lint - Lint code
  • npm run format - Format code

Project Structure

course_comparator/
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ config/
β”‚   β”‚   └── db.js
β”‚   β”‚   β”œβ”€β”€ data/
β”‚   β”‚   β”‚   β”œβ”€β”€ course.js
β”‚   β”‚   β”‚   β”œβ”€β”€ domain.js
β”‚   β”‚   β”‚   └── section.js
β”‚   β”‚   β”œβ”€β”€ middleware/
β”‚   β”‚   β”‚   └── authMiddleware.js
β”‚   β”‚   β”œβ”€β”€ models/
β”‚   β”‚   β”‚   β”œβ”€β”€ Chat.js
β”‚   β”‚   β”‚   β”œβ”€β”€ Course.js
β”‚   β”‚   β”‚   β”œβ”€β”€ Domain.js
β”‚   β”‚   β”‚   β”œβ”€β”€ Review.js
β”‚   β”‚   β”‚   β”œβ”€β”€ Section.js
β”‚   β”‚   β”‚   β”œβ”€β”€ Subscriber.js
β”‚   β”‚   β”‚   └── Users.js
β”‚   β”‚   β”œβ”€β”€ routes/
β”‚   β”‚   β”‚   β”œβ”€β”€ adminRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ chatRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ courseAdminRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ courseRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ domainAdminRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ domainRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ sectionRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ subscriberRoutes.js
β”‚   β”‚   β”‚   β”œβ”€β”€ uploadRoutes.js
β”‚   β”‚   β”‚   └── userRoutes.js
β”‚   β”‚   β”œβ”€β”€ server.js
β”‚   β”‚   └── package.json
β”‚   β”œβ”€β”€ frontend/
β”‚   β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ Admin/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ Chat/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ Common/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ Courses/
β”‚   β”‚   β”‚   β”‚   └── Layout/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ pages/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ redux/
β”‚   β”‚   β”‚   β”‚   β”‚   └── slices/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ assets/
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ App.jsx
β”‚   β”‚   β”‚   β”‚   └── main.jsx
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ package.json
β”‚   β”‚   β”‚   β”‚   └── vite.config.js
β”‚   β”‚   β”‚   └── README.md
β”‚   └── README.md

πŸ”§ Configuration

Environment Variables

Backend (.env)

  • PORT - Server port (default: 5000)
  • MONGO_URI - MongoDB connection string
  • JWT_SECRET - JWT secret key
  • CLOUDINARY_CLOUD_NAME - Cloudinary cloud name
  • CLOUDINARY_API_KEY - Cloudinary API key
  • CLOUDINARY_API_SECRET - Cloudinary API secret
  • NODE_ENV - Environment (development/production)

Frontend (.env)

  • VITE_BACKEND_URL - Backend API URL

πŸ§ͺ Testing

Backend Tests

cd backend
npm test

Frontend Tests

cd frontend
npm test

πŸ“± Responsive Design

The application is fully responsive and optimized for:

  • Mobile: 320px - 768px
  • Tablet: 768px - 1024px
  • Desktop: 1024px+

πŸ”’ Security Features

  • JWT-based authentication
  • Password hashing with bcrypt
  • CORS protection
  • Helmet security headers
  • Rate limiting
  • Input validation
  • XSS protection

πŸš€ Deployment

Backend Deployment

  1. Set up environment variables
  2. Build the application
  3. Deploy to your preferred platform (Heroku, Vercel, etc.)

Frontend Deployment

  1. Build the application: npm run build
  2. Deploy the dist folder to your hosting platform

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests if applicable
  5. Submit a pull request

πŸ“„ License

This project is licensed under the MIT License.

πŸ†˜ Support

For support and questions:

  • Create an issue in the repository
  • Contact the development team

πŸ”„ Updates

Stay updated with the latest features and improvements by:

  • Following the repository
  • Checking the releases page
  • Reading the changelog

Built with ❀️ by the Course Comparator Team

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages