Skip to content

Repository files navigation

mesh-word-chain

pages version license

A quick peer-to-peer word chain with shared turns and a round clock.

Live → https://baditaflorin.github.io/mesh-word-chain/

Source → https://github.com/baditaflorin/mesh-word-chain

Tip the dev (buy a coffee) → https://www.paypal.com/paypalme/florinbadita


screenshot

Two peers, side-by-side, in the same room. Drop a tests/demo/scenario.mjs exporting default async (a, b) => … and run npm run demo to regenerate docs/preview.png plus docs/demo-a.webm / docs/demo-b.webm clips.

preview

What it is

A rootless-computing peer-to-peer browser app. No backend of its own beyond the self-hosted WebRTC stack listed below. State lives in a Yjs mesh shared by everyone in the same room.

Read the principles → https://baditaflorin.github.io/rootless-computing/principles.html

Quickstart

Open the live URL on two devices in the same room (set in ⚙ settings, or scan the room QR). Everything else is in-app.

For local hacking:

git clone https://github.com/baditaflorin/mesh-common
git clone https://github.com/baditaflorin/mesh-word-chain
cd mesh-word-chain
npm install
npm run dev

mesh-common must sit as a sibling directory because package.json references it via file:../mesh-common.

Self-hosted infrastructure

Repo Endpoint Purpose
https://github.com/baditaflorin/signaling-server wss://turn.0docker.com/ws y-webrtc signaling fan-out
https://github.com/baditaflorin/turn-token-server https://turn.0docker.com/credentials HMAC TURN creds, 1-hour TTL
https://github.com/baditaflorin/coturn-hetzner turn:turn.0docker.com:3479 TURN relay

Settings overrides

The settings drawer lets the user override signaling and TURN endpoints. localStorage keys:

  • mesh-word-chain:signalingUrl
  • mesh-word-chain:turnTokenUrl
  • mesh-word-chain:iceServers
  • mesh-word-chain:room

If endpoints are blank or unreachable, the app falls back to STUN-only.

Version + commit on every screen

The bottom-right footer on every screen of the live app shows:

  • source → this repo
  • tip ♥ → PayPal
  • vX.Y.Z · <short-sha> — version from package.json plus the build-time git commit

Build & deploy

GitHub Pages serves the committed docs/ directory on the main branch. There is no GitHub Actions build workflow; local Husky-style hooks gate formatting / typecheck / smoke build before each push.

npm run smoke                                    # build + sanity-check docs/
bash ../mesh-common/scripts/screenshot-app.sh    # regenerate docs/screenshot.png

Privacy

Everything you publish to a room is visible to every peer in that room. Your local device's name, key, and choices stay local. Cryptographic signatures prove who wrote each entry; they do not prevent peers from reading or copying entries. The room URL is the access control — share it deliberately.

See docs/privacy.md for the full threat model — capabilities used, what other peers in the mesh see, what the self-hosted infra sees, what stays local.

License

MIT — see LICENSE.

About

A quick peer-to-peer word chain with shared turns and a round clock.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages