Skip to content

kaurmanjot20/ektaal

Repository files navigation

EkTaal

Production-ready real-time music sync platform.

Features

  • Real-time Sync: Synced playback across multiple clients using Supabase Realtime.
  • JioSaavn Integration: Search and stream high-quality audio.
  • Queue Management: Shared queue controlled by Host.
  • Dark Mode UI: Premium, matte black aesthetic.

Setup

  1. Install Dependencies

    npm install
  2. Environment Variables Create .env.local:

    NEXT_PUBLIC_SUPABASE_URL=your_supabase_url
    NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_key
  3. Database Schema (Supabase) Run this SQL in your Supabase SQL Editor:

    create table rooms (
      id text primary key,
      current_song jsonb,
      queue jsonb,
      is_playing boolean default false,
      started_at bigint,
      created_at timestamptz default now()
    );
    
    -- Enable Realtime for 'rooms' table (Optional, we use Broadcast channels mostly but good for debug)
    alter publication supabase_realtime add table rooms;
  4. Run Locally

    npm run dev

Sync Logic

  • Host sets the startedAt timestamp (server-side time approximation or host local time).
  • Listeners calculate offset = (Date.now() - startedAt) / 1000.
  • If drift > 300ms, the client auto-seeks to the correct timestamp.
  • Late joiners fetch the snapshot from the rooms table to sync immediately.

Tech Stack

  • Next.js 15 (App Router)
  • Tailwind CSS v4
  • Supabase (Postgres + Realtime)

About

Your no-login, realtime music sync platform.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors