← All work

A live class quiz on Cloudflare

What I built

A quiz for the end of a teaching week. The coach hosts it on one screen, and learners join on their phones with a PIN or QR code, with no sign-in.

How it works

  • One Durable Object per game. Each PIN gets its own room on Cloudflare, and players stay in sync over a WebSocket.
  • Games clean up after themselves. Each one deletes itself after 12 hours.

How I tested it

  • A protocol test covering joining, broadcasts, late joiners and writes to the wrong game.
  • A browser test with one host and two simulated phones playing a question through to the scores.