Skip to content

feat: add recently edited section to /live - #118

Merged
tasercake merged 1 commit into
mainfrom
worktree/live-recent
Jul 2, 2026
Merged

feat: add recently edited section to /live#118
tasercake merged 1 commit into
mainfrom
worktree/live-recent

Conversation

@tasercake

Copy link
Copy Markdown
Owner

Summary

  • Broadcast edits on shared 'edits' PubSub topic (one extra line in DocumentServer)
  • /live page subscribes to edits topic, tracks recent edits in memory
  • Shows up to 10 most recently edited documents that are NOT currently live
  • Real-time: new edits appear instantly, docs transition between sections as they go live/offline
  • Fetches content excerpts for recent docs on first edit broadcast
  • A document never appears in both sections simultaneously

Design

Two real-time systems feed /live:

  1. Presence → live section (who's editing right now)
  2. Edits broadcast → recent section (what was edited recently)

When a doc goes live, it drops from recent. When a writer closes their tab, the doc reappears in recent (if it was edited). No polling, no GenServer, no ETS.

- Broadcast edits on shared 'edits' PubSub topic
- Track recent edits in LiveLive with real-time updates
- Show up to 10 most recently edited non-live docs
- Fetch excerpts for recent docs on first edit broadcast
- Docs never appear in both live and recent sections
@tasercake
tasercake merged commit 4fcc190 into main Jul 2, 2026
1 check passed
@tasercake
tasercake deleted the worktree/live-recent branch July 2, 2026 09:52
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