Last active
February 28, 2018 10:26
-
-
Save arikanmstf/51d85a3de3297077953b3905c837997c to your computer and use it in GitHub Desktop.
This file contains hidden or 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
navigator.serviceWorker.register('/assets/service-worker.js', { scope: '/' }) | |
.then(function() { | |
return navigator.serviceWorker.ready; | |
}) | |
.then(function(registration) { | |
console.log(registration); // service worker is ready and working... | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment