forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on mainFiltered to crates/forge-web/assets/offline.jsClear filter

2026-10-21

✨ feat: the page recovers on its own when the server restartsAhmet Kaan Gümüş · 8ae0722
✨ feat: the page recovers on its own when the server restarts

Every page holds a stream to /-/alive. While it is down a bar says the server is
restarting and the page stays put. Soft navigations are kept and made again when the
server is back; a form post is never sent again and the bar asks for a new submit.
A full load during an outage gets an offline page from the service worker, which
reloads itself once the server answers. Every event stream sends retry: 1000, and
streams closed by a proxy's error are reopened by the page after 1, 2, then 3 s.