Findings No. 6
When a tab runs out of memory there is no event
iOS kills and reloads the tab; Chrome shows its error page; code cannot observe its own death. Leave a marker in sessionStorage when a heavy load begins.
When a browser tab dies of memory exhaustion, no event fires and no handler runs. iOS kills the tab and silently reloads it; desktop Chrome shows its error page. Code cannot observe its own death, and navigator.deviceMemory exists only in Chrome and Edge, so you cannot reliably predict the ceiling either. WebKit adds a sharper edge: decodeAudioData on a very large file may simply never return.
The pattern that survives this: leave a marker in sessionStorage when a heavy load begins and clear it when the load completes. Finding a fresh marker for the same inputs on the next visit means the last attempt died mid-load, and the code can choose a lighter path instead of dying the same way twice.
Receipt: Stem Shovel's stem player (engine.svelte.ts LOAD_MARKER, commit 6be87bd; docs/audio-engine.md, "When the browser runs out of memory").