-
-
Save ankitamasand/164b8d6657654c16e9ea4fb54bf18c8c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self.addEventListener('activate', (event) => { | |
event.waitUntil( | |
self.clients.matchAll().then ( (client) => { | |
client.postMessage({ | |
msg: 'Hey, from service worker! I\'m listening to your fetch requests.', | |
source: 'service-worker' | |
}) | |
}) | |
) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment