Project X is a high-performance, scalable video streaming platform built with the MERN stack. It features an advanced search engine, real-time view tracking, and a professional-grade studio dashboard for creators.
Project X follows a decoupled client-server architecture with an emphasis on Atomic Operations and Aggregation Pipelines for data integrity.
- Upload Phase: Videos are processed via
Multerand stored in Cloudinary. Metadata (Duration, Format, Title) is extracted and saved to MongoDB. - Search Phase: A unified search controller uses MongoDB
$regexand$lookupto search across both Video Titles and Creator Profiles simultaneously. - Playback & View Sync: When a video is played, the frontend triggers an atomic
$incoperation on the backend, ensuring views are counted uniquely per user.
- Dual-Core Search: Find videos and creators in a single search bar with real-time dropdown suggestions.
- Smart Theater: High-end video player with auto-play, custom controls, and responsive layout.
- Creator Studio: Advanced dashboard for managing uploads, toggling public/private status, and tracking performance.
- Public Profiles: Dynamic creator pages allowing users to browse content from their favorite uploaders.
- Secure Auth: JWT-based authentication with Access and Refresh tokens stored in HTTP-only cookies.
- React.js (Vite): Fast, modern UI development.
- Tailwind CSS: Utility-first styling with custom "Prism" glassmorphism effects.
- Framer Motion: Smooth layout transitions and interactive animations.
- Lucide React: Beautiful, consistent iconography.
- Node.js & Express: Robust server-side logic and RESTful API.
- MongoDB & Mongoose: NoSQL database with complex aggregation pipelines for data fetching.
- Cloudinary: Cloud storage for optimized video delivery and thumbnail generation.
- Multer: Middleware for handling
multipart/form-datauploads.
βββ backend/
β βββ src/
β β βββ controllers/ # Business logic (Video, User, Search)
β β βββ models/ # MongoDB Schemas (Video, User, View)
β β βββ routes/ # Express API endpoints
β β βββ middlewares/ # JWT Verify, Multer, Error handling
β β βββ app.js # Express configuration
βββ frontend/
β βββ src/
β β βββ components/ # Reusable UI elements (Navbar, Card)
β β βββ pages/ # SearchPage, WatchVideo, Dashboard
β β βββ context/ # AuthContext, ThemeContext
β β βββ api/ # Axios instance and API calls