Skip to content

Latest commit

 

History

35 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎬 AngSync Room

A real-time YouTube video synchronization app that allows multiple users to watch the same video together and enjoy the real sync. image image

🚀 Features

✅ Create or join a sync room with a unique Room ID.
✅ Watch YouTube videos in sync with others.
✅ Play, pause, and seek functionality is synchronized across all users in the room.
✅ Change the video URL dynamically.

🛠️ Technologies Used

  • Frontend: HTML, JavaScript, TailwindCSS 🎨
  • Backend: Node.js, Express.js 🖥️
  • WebSockets: For real-time video synchronization 🔄
  • YouTube IFrame API: For embedding and controlling YouTube videos 🎥

⚙️ Installation & Setup

📌 Prerequisites

📝 Steps

  1. Clone the repository:
    git clone https://github.com/your-repo/angsync-room.git
  2. Install dependencies:
    npm install
  3. Start the server:
    node server.js
  4. Open http://localhost:8080/ in your browser. 🌐

🛠️ How It Works

Server-side (server.js) 🖥️

  • Uses Express.js to serve the index.html file.
  • Uses WebSockets to establish real-time communication between users.
  • Manages rooms and keeps track of video state (play, pause, seek, and URL changes).

Client-side (index.html & JavaScript) 🎭

  • Connects to the WebSocket server.
  • Loads and controls the YouTube video using the YouTube IFrame API.
  • Sends and receives synchronization messages (play, pause, seek, change URL) through WebSockets.

🔄 WebSocket Events

🎯 Event Type 🔁 Sent By 📌 Purpose
join Client User joins a room 👥
sync Server Sends current video state to new users 🔄
play Client Notifies all users to play video ▶️
pause Client Notifies all users to pause video ⏸️
seek Client Synchronizes video position ⏩
changeUrl Client Updates video URL for all users 🔗

🔧 Issues & Improvements

🚨 Sometimes pause/play actions don’t sync correctly. Possible improvement: Implement a timestamp-based synchronization mechanism.
⚡ Enhance error handling for WebSocket disconnections.
🎨 UI/UX improvements for a better user experience.

📜 License

📝 MIT License

👤 Author

📌 Jivan Jamdar 🚀

About

Connect with your friends & enjoy the show on streaming media

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages