How ujjwalsaini07/skystream works
Project Type & Purpose
• SkyStream is a full-stack, real-time web application that enables instantaneous screen sharing and integrated chat without downloads.
• Frontend: React.js SPA; Backend: Firebase (Auth, Cloud Functions, Firestore); Containerization: Docker; Deployment: Vercel/Docker Compose.
File Structure (High-Level)
• Top level:
• Dockerfile + docker-compose.yml → container build & orchestration
• firebase.json + functions/ → Firebase backend functions
• src/, public/, index.html → React single-page application
• vite.config.js / webpack.config.js → build pipelines
• src/:
• components/ (ChatRoom, HelpCenter, common, ui, magicui) → UI modules
• pages/ → route-driven views (Home, ChatRoom, About, ContactUs, HelpCenter)
• lib/utils.js, hooks/ → shared logic and custom hooks
Key Insights from README
• Real-time chat + screen-sharing uses Firebase SDK for Auth, Firestore, and Cloud Functions.
• UI styling: Tailwind CSS + SCSS + ShadCN component library.
• Dockerization for local development and production deployments.
Core Components & Their Relationships
a. Frontend (Browser/Client)
• React SPA served via Vercel or Dockerized Node static server.
• Modules:
• UI Layer (components/ui, magicui)
• Feature Routes (pages/, components/ChatRoom, HelpCenter)
• Utilities (hooks/, lib/utils.js)
b. Backend (Firebase)
• Authentication Service (Firebase Auth)
• Real-time Database (Firestore)
• Business Logic (Cloud Functions in functions/index.js)
c. Deployment & Infrastructure
• Containerization (Dockerfile, docker-compose)
• Hosting (Vercel or custom Docker host)
• Configuration (firebase.json)
d. External Services
• Firestore for data storage
• Firebase Auth for user identity
• Vercel (optional) for CDN + global hosting
Architectural Patterns & Design Principles
• SPA Pattern: React router → pages/ directory
• Component-based UI → logical separation in src/components
• Feature-folder organization for ChatRoom, HelpCenter
• Serverless backend pattern → Firebase Functions handle API logic
• Infrastructure as code → docker-compose.yml + Firebase config
3. Inside host, show “React App.” Break this into:
• UI Components (pages & components folders)
• State & Hooks (hooks/, lib/)
• Firebase Auth service (sign-in)
• Firestore DB (chat messages, room data)
• Firebase Cloud Functions (createRoom, joinRoom handlers)
5. Firebase subsystem:
• Firestore accessed both by client and functions
6. Optionally, include Docker:
• docker-compose.yml linking frontend container & functions container