GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - supabase/multiplayer.dev

BranchesTags
Open more actions menu

Latest commit

 

History

88 Commits
88 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
app
app
 
 
components
components
 
 
hooks
hooks
 
 
lib
lib
 
 
.env.example
.env.example
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
components.json
components.json
 
 
eslint.config.mjs
eslint.config.mjs
 
 
middleware.ts
middleware.ts
 
 
migrate.sql
migrate.sql
 
 
next.config.ts
next.config.ts
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
postcss.config.mjs
postcss.config.mjs
 
 
profile.json
profile.json
 
 
tsconfig.json
tsconfig.json
 
 

Repository files navigation

multiplayer.dev

The open source demo app for Supabase Realtime. Open multiplayer.dev in a few browser tabs to see other visitors' cursors, who is online, and a shared chat, all delivered over Realtime.

What this demo shows

  • Presence – the avatar stack in the top corner shows who is currently online. Realtime tracks each connection and notifies everyone else when someone joins or leaves, even if they drop unexpectedly.
  • Broadcast – cursor positions and emoji reactions are sent as short-lived Broadcast messages that fan out to everyone in the room without being stored in the database.
  • Broadcast from Database – chat messages are inserted into a Postgres table, and a trigger calls realtime.send to broadcast each one to the room. See migrate.sql and the Broadcast from Database docs.
  • Broadcast Replay – the chat channel is private and asks Realtime to replay recent messages, so you see recent history when you join or reconnect. Replayed messages are shown dimmed.
  • Authorization – private channels are checked against Row Level Security policies on realtime.messages. See the Realtime Authorization docs.

Getting started

  1. Create a Supabase project and run migrate.sql in the SQL editor to set up the chat table, trigger, and policies.

  2. Copy .env.example to .env.local and fill in your project URL and API key (find them in your project's API settings).

  3. Install dependencies and start the dev server:

    npm install
    npm run dev

Learn more

  • Supabase Realtime, with Multiplayer Features – the 2022 launch post for this demo, covering Presence and Broadcast
  • Realtime: Broadcast from Database – send database changes to clients with Broadcast
  • Realtime: Broadcast Replay – let private channels retrieve earlier messages
  • Realtime Authorization docs – secure channels with RLS policies
  • Realtime documentation
  • Supabase UI Library Realtime components – drop-in components for building features like these: Realtime Cursor, Realtime Avatar Stack, and Realtime Chat

About

multiplayer.dev

Resources

Readme

Code of conduct

Code of conduct

Contributing

Contributing

Security policy

Security policy
Activity
Custom properties

Stars

15 stars

Watchers

1 watching

Forks

5 forks
Report repository

Sponsor this project

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.