Skip to content

perf(dashboard): reconcile store writes, key repo groups, and persist snapshot in IndexedDB - #177

Draft
wgordon17 wants to merge 6 commits into
gordon-code:mainfrom
wgordon17:feat/site-modernization-pr3
Draft

wgordon17 wants to merge 6 commits into
gordon-code:mainfrom
wgordon17:feat/site-modernization-pr3

Conversation

@wgordon17

@wgordon17 wgordon17 commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Switch dashboard store writes in DashboardPage to keyed reconcile(..., { key: "id", merge: true }) and key repository and workflow group loops across IssuesTab, PullRequestsTab, and ActionsTab so background refreshes preserve existing DOM nodes without scroll-lock workarounds.
  • Move the cached dashboard snapshot from synchronous localStorage to a dedicated github-tracker-snapshot IndexedDB store with immediate/debounced writes (hot-poll cycles persist too, ~2–4 ms of structured clone per cycle at typical sizes, so reloads show current check statuses), a 5,000-item cap that discards the stored record, eager clearing in auth.ts, identityEpoch() / StaleIdentityError guards across all polling and mutation paths, and a Privacy page entry. The snapshot is cleared when a token expires, so signing back in as the same user after a 401 starts without it — unchanged from before, since expireToken already removed the localStorage copy — and the expireToken docstring now says so.
  • Tighten post-deploy WAF smoke test status assertions for /_app/nonexistent.js and metadata paths and sync the verbatim Cloudflare WAF rules in DEPLOY.md.

@wgordon17
wgordon17 force-pushed the feat/site-modernization-pr3 branch from 88661c7 to e70016b Compare October 30, 2026 21:37
- Treat any error from a poll or hot-poll cycle started under a previous
  identity as stale: never touch loading, expire the token, or surface errors
- Discard the stored snapshot when a write exceeds the item cap and clear
  pending snapshot writes on cross-tab identity switches
- Remove test-mock-shaped production code; require epoch callback params;
  add SNAPSHOT_VERSION, Privacy page snapshot disclosure, and tests
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