// In host's sw.js
const CACHE_VERSION = 'v1'; // Change this to force service worker update
importScripts('/js/wirechat/sw.js');


// Example: Custom event listener in main SW
self.addEventListener('install', event => {
    console.log('Main Service Worker Installed - ' + CACHE_VERSION);
    self.skipWaiting();
});

self.addEventListener('activate', event => {
    console.log('Main Service Worker Activated');
    event.waitUntil(self.clients.claim());
});
