How do I run code when my Sveltekit application is exiting?
I have a hooks.server.ts file that initializes a DB connection when the app starts. If my server shuts off, how do I close the connection?
Thanks
How do I run code when my Sveltekit application is exiting?
I have a hooks.server.ts file that initializes a DB connection when the app starts. If my server shuts off, how do I close the connection?
Thanks