Skip to content

TheFakeCreator/campus-syllabus-hub

Repository files navigation

πŸŽ“ Campus Syllabus Hub

Node.js React TypeScript MongoDB License: MIT

A modern, comprehensive web application designed for college students to easily discover and access academic resources including syllabus, lecture videos, notes, book references, and guided learning roadmaps - all organized by branch, year, semester, and subject.

🌟 Features

πŸ“š Academic Resource Management

  • Structured Organization: Resources organized by Branch β†’ Year β†’ Semester β†’ Subject
  • Multiple Resource Types: Syllabus, lecture videos, notes, books, and reference materials
  • Quality Scoring: Community-driven quality ratings for resources
  • Advanced Search: Full-text search with filters by type, branch, semester, and subject
  • Provider Integration: Support for popular educational platforms (NPTEL, Gate Smashers, CodeWithHarry, etc.)

πŸ—ΊοΈ Guided Learning Roadmaps

  • Step-by-Step Learning Paths: Structured roadmaps for exam preparation (midsems, endsems, practicals)
  • Progress Tracking: Track completion status with local storage persistence
  • Difficulty Levels: Beginner, intermediate, and advanced roadmaps
  • Resource Integration: Direct links to relevant study materials within each step
  • Rating System: Community ratings and feedback for roadmaps

πŸ‘₯ User Management & Roles

  • Role-Based Access Control: Student, Moderator, and Admin roles
  • Secure Authentication: JWT-based auth with refresh tokens and httpOnly cookies
  • Contribution System: Moderators can add/edit resources, admins manage everything
  • User Profiles: Track contributed resources and learning progress

πŸ”§ Developer Experience

  • Modern Tech Stack: React + TypeScript + Node.js + MongoDB
  • Monorepo Structure: Clean separation between frontend and backend
  • Type Safety: End-to-end TypeScript with shared type definitions
  • Quality Tools: ESLint, Prettier, Husky, commitlint, comprehensive testing
  • Docker Support: Easy development and deployment with Docker Compose

πŸ—οΈ Architecture

campus-syllabus-hub/
β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ web/          # React + Vite + Tailwind CSS frontend
β”‚   └── api/          # Node.js + Express + MongoDB backend
β”œβ”€β”€ packages/
β”‚   β”œβ”€β”€ eslint-config/    # Shared ESLint configuration
β”‚   └── tsconfig/         # Shared TypeScript configurations
└── docs/             # Comprehensive documentation

🎨 Frontend (React + TypeScript)

  • Framework: Vite + React 18 with TypeScript
  • Styling: Tailwind CSS v3 with dark mode support
  • Routing: React Router v6 with future flags enabled
  • State Management: Zustand for lightweight state management
  • Forms: React Hook Form + Zod validation
  • HTTP Client: Axios with interceptors for auth
  • Testing: Vitest + React Testing Library

βš™οΈ Backend (Node.js + TypeScript)

  • Framework: Express.js with TypeScript
  • Database: MongoDB with Mongoose ODM
  • Authentication: JWT (access + refresh tokens) with httpOnly cookies
  • Validation: Zod for request/response validation
  • Security: Helmet, CORS, rate limiting, XSS protection, mongo sanitization
  • Logging: Pino structured logging
  • Testing: Jest/Vitest + Supertest for API testing

πŸš€ Quick Start

Prerequisites

  • Node.js 18+ and pnpm 8+
  • MongoDB 6+ (local installation or MongoDB Atlas)
  • Git for version control

1. Clone and Install

git clone <repository-url>
cd campus-syllabus-hub
pnpm install

2. Environment Setup

# Backend environment
cp apps/api/.env.sample apps/api/.env
# Edit apps/api/.env with your MongoDB URI and JWT secrets

# Frontend environment  
cp apps/web/.env.sample apps/web/.env
# Edit apps/web/.env if needed (default values work for local development)

3. Database Setup

# Start MongoDB (if running locally)
# OR ensure MongoDB Atlas connection is configured

# Seed the database with sample data
cd apps/api
pnpm seed

4. Development Servers

# Terminal 1: Start API server
cd apps/api
pnpm dev

# Terminal 2: Start web server  
cd apps/web
pnpm dev

πŸŽ‰ Access the application:

πŸ“– Documentation

πŸ› οΈ Development Commands

# Root level commands
pnpm install              # Install all dependencies
pnpm -r build            # Build all packages
pnpm -r dev              # Start all dev servers
pnpm -r test             # Run all tests
pnpm -r lint             # Lint all packages
pnpm -r typecheck        # TypeScript type checking

# API specific
pnpm --filter api dev    # Start API dev server
pnpm --filter api test   # Run API tests
pnpm --filter api seed   # Seed database

# Web specific  
pnpm --filter web dev    # Start web dev server
pnpm --filter web test   # Run frontend tests
pnpm --filter web build # Build for production

🐳 Docker Development

# Start all services with Docker Compose
docker-compose up -d

# View logs
docker-compose logs -f

# Stop services
docker-compose down

πŸ§ͺ Testing

# Run all tests
pnpm -r test

# Run tests with coverage
pnpm -r test -- --coverage

# Run specific test suites
pnpm --filter api test
pnpm --filter web test

πŸ“¦ Project Structure

β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ api/src/
β”‚   β”‚   β”œβ”€β”€ features/          # Feature-based modules
β”‚   β”‚   β”‚   β”œβ”€β”€ auth/         # Authentication
β”‚   β”‚   β”‚   β”œβ”€β”€ catalog/      # Academic structure (branches, subjects)  
β”‚   β”‚   β”‚   β”œβ”€β”€ resources/    # Learning resources
β”‚   β”‚   β”‚   └── roadmaps/     # Learning roadmaps
β”‚   β”‚   β”œβ”€β”€ middleware/       # Express middlewares
β”‚   β”‚   β”œβ”€β”€ utils/           # Utility functions
β”‚   β”‚   └── types/           # TypeScript definitions
β”‚   └── web/src/
β”‚       β”œβ”€β”€ pages/           # Route components
β”‚       β”œβ”€β”€ components/      # Reusable UI components
β”‚       β”œβ”€β”€ lib/            # Utilities and API client
β”‚       └── types/          # Frontend type definitions
β”œβ”€β”€ packages/               # Shared packages
└── docs/                  # Documentation

🀝 Contributing

We welcome contributions! Please see our Contributing Guide for details on:

  • Code of conduct
  • Development workflow
  • Pull request process
  • Coding standards
  • Testing requirements

πŸ“‹ Roadmap

🎯 Current Version (v1.0)

  • βœ… Core resource management
  • βœ… Guided learning roadmaps
  • βœ… User authentication & authorization
  • βœ… Search and filtering
  • βœ… Progress tracking

πŸš€ Future Enhancements

  • Social Features: Upvoting, commenting, resource recommendations
  • Admin Dashboard: Analytics, content moderation, user management
  • Bulk Import: CSV/Excel upload for batch resource addition
  • University Profiles: Multi-university support with custom curricula
  • Mobile App: React Native mobile application
  • Offline Support: PWA with offline resource caching
  • AI Integration: Smart resource recommendations and study path optimization

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments

  • Educational Platforms: NPTEL, Gate Smashers, CodeWithHarry for inspiring the resource structure
  • Open Source Community: All the amazing libraries and tools that make this project possible
  • Contributors: Everyone who helps make this platform better for students

Built with ❀️ for students, by developers who understand the struggle of finding quality study materials.

About

Open-source platform for college students to share roadmaps, curriculums, PYQs, notes, and syllabi.

Topics

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages