diff options
author | Navan Chauhan <navanchauhan@gmail.com> | 2018-01-21 17:12:14 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-21 17:12:14 +0530 |
commit | 5c2f28983b2fe983471677650f102067bee14445 (patch) | |
tree | 927a7d807cfa9c0be739fab698fd7ddb1f671eb4 /index.html | |
parent | ccc72d6cb0446a150a2bbe2e780daa64226d9453 (diff) |
Update index.html
Diffstat (limited to 'index.html')
-rw-r--r-- | index.html | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -2,6 +2,17 @@ <html lang="en" > <head> +<script>if ('serviceWorker' in navigator) { + window.addEventListener('load', function() { + navigator.serviceWorker.register('/sw.js').then(function(registration) { + // Registration was successful + console.log('ServiceWorker registration successful with scope: ', registration.scope); + }, function(err) { + // registration failed :( + console.log('ServiceWorker registration failed: ', err); + }); + }); +}</script> <meta charset="UTF-8"> <meta name="referrer" content="origin"> <meta name="Description" content="Hi! This is my personal website and it also houses comprehensive guides about my projects"> |