HummingBirdAnimeClient/frontEndSrc/js/sw.js
Timothy J. Warren 5346ce7d89
Some checks failed
timw4mail/HummingBirdAnimeClient/pipeline/head There was a failure building this commit
Drastically simplify setup for bundling js files
2021-04-23 18:58:51 -04:00

8 lines
277 B
JavaScript

// Start the service worker, if you can
if ('serviceWorker' in navigator) {
navigator.serviceWorker.register('/sw.js').then(reg => {
console.log('Service worker registered', reg.scope);
}).catch(error => {
console.error('Failed to register service worker', error);
});
}