Frontend caching for live status to prevent reload on back button #9
Labels
No labels
bug
codex
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
wandabastyle/twitch_relay#9
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
When the user navigates away from the front page (e.g., to watch a stream) and then hits the browser back button to return, the live status currently re-fetches from the server even if cached data exists. The server already has a prewarm worker that caches live status every 60 seconds with a 30 second TTL, but the frontend always fetches fresh on page mount.
Expected Behavior
Selected Solution: Frontend Caching
Implementation
web/src/lib/api.ts- Add caching layer togetLiveStatus()web/src/routes/+page.svelte- UpdateloadLiveStatus()initialize()- let API handle cachingWhy This Approach
Priority: Low (UX improvement)
Labels: enhancement