Last active
January 26, 2018 14:56
-
-
Save mnsmarcelo/ff288f691c4e0f1f75505a152660bbea 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('install', function (event) { | |
console.log('[Service Worker] Instalando Service Worker...', event); | |
}); | |
self.addEventListener('activate', function (event) { | |
console.log('[Service Worker] Ativando Service Worker ...', event); | |
return self.clients.claim(); | |
}); | |
self.addEventListener('fetch', function (event) { | |
console.log('[Service Worker] Procurando algo...', event); | |
event.respondWith(fetch(event.request)); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment