Skip to content

docs: rewrite README to match the actual library#18

Merged
joelshejar merged 1 commit into
mainfrom
docs/readme-rewrite
May 10, 2026
Merged

docs: rewrite README to match the actual library#18
joelshejar merged 1 commit into
mainfrom
docs/readme-rewrite

Conversation

@joelshejar
Copy link
Copy Markdown
Member

Summary

The previous README was a project-setup placeholder — "coming soon", empty checklist, "Like Istio for the frontend". It hasn't tracked reality since v1 landed (PR #4) and definitely doesn't reflect the 16 PRs that came after.

This rewrites it to ~200 lines covering what someone evaluating TabMesh actually needs to decide adoption.

Sections

  • One-paragraph framing of the cross-tab pain it solves.
  • Quickstart — minimal example + React snippet. Including `workerVersion` in the example so users land in the right deploy pattern from day one.
  • Architecture — small diagram + brief mode summary.
  • Gotchas — the section anyone evaluating should read first:
    • SharedWorker name caching → set `workerVersion` per deploy
    • `delivered` != backend-processed (will tighten with `ackMode: 'server'`)
    • No replay buffer for late-joining tabs (by design, per CONTEXT.md)
    • In-browser only, same-origin only
    • Mobile fallback paths get less coverage
    • SW handoff requires `deliveryUrl`
  • Configuration — single-table reference cross-referencing `types.ts`.
  • System events — the runtime-event surface for error handling.
  • Development — the commands a contributor needs.
  • Pre-1.0 status — explicit notice that the API may change.

Why prioritise gotchas

Anyone scanning a 200-line README skips ~80% of it. Putting the sharp edges right after Quickstart means the people who would have hit them and filed an issue self-select out before adopting — saving everyone time.

Test plan

  • Renders cleanly on the GitHub markdown preview
  • All linked paths exist (`CONTEXT.md`, `docs/adr/`, `packages/playground/scripts/build-worker.mjs`, `packages/core/src/types.ts`, `e2e/multi-tab.spec.ts`)

The previous README was a project-setup placeholder ("coming soon",
empty checklist, "Like Istio for the frontend"). It hadn't tracked
reality since v1 landed.

New README covers:

- One-paragraph "what it solves" framed around the concrete cross-tab
  pain (one WS instead of N, durable outbox, logout flow).
- Quickstart with a minimal example and a React snippet.
- Architecture diagram + brief mode summary (SharedWorker primary,
  elected-leader fallback, optional SW handoff).
- Gotchas — the section anyone evaluating the library actually needs:
    - SharedWorker name caching → set workerVersion per deploy
    - delivered != backend-processed (until ackMode: 'server')
    - No replay buffer for late-joining tabs (by design)
    - In-browser, same-origin only
    - Mobile fallback paths get less coverage
    - SW handoff requires deliveryUrl
- Configuration table cross-referencing types.ts.
- System events list.
- Development commands.
- Pre-1.0 status.

About 200 lines. Intent is to make the gotchas the most prominent
section after quickstart so readers can self-evaluate fit before
investing in adoption.
@joelshejar joelshejar merged commit 3579f87 into main May 10, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant