Svelte's onDestroy function is tied to the currently executing component, if you want to run cleanup in a rootful effect you'd have to do this nasty incantation >.>
```
$effect(() => {
return () => {
// cleanup
};
});
```
hmmm svelte only provides a library template with sveltekit
using sveltekit wouldn't work here since i'm publishing a router implementation, i guess i'll have to try and see
[rachelbythebay.com/w/2025/03/26/a…](https://rachelbythebay.com/w/2025/03/26/atop/ )
> Okay, first off, everybody breathe. Everyone is freaking out. This is not the way to do this.
or maybe don't do vagueposting wrt disclosures 😭