diff --git a/client/src/state.ts b/client/src/state.ts index d9c00e7..cc140cd 100644 --- a/client/src/state.ts +++ b/client/src/state.ts @@ -49,6 +49,7 @@ export const state = reactive({ error(event) window.location = window.location }) + window.addEventListener('beforeunload', () => source.close()) }, async repopulate() { this.state = State.Fetching