Ensure users that install pokerogue as a PWA do not remain on the old version

This commit is contained in:
Sirz Benjie 2025-08-25 14:08:05 -05:00
parent 1f4efa0e27
commit 56752d6f4a
No known key found for this signature in database
GPG Key ID: 4A524B4D196C759E

View File

@ -1,3 +1,9 @@
/// <reference lib = "WebWorker" />
self.addEventListener('install', function () { self.addEventListener('install', function () {
console.log('Service worker installing...'); console.log('Service worker installing...');
}); });
self.addEventListener('activate', (event) => {
// @ts-expect-error: See https://github.com/microsoft/TypeScript/issues/14877
event.waitUntil(self.clients.claim());
})