Hi @NewMedia and thank you for your kind words.
The icon that you are seeing is for Microsoft To Do and has nothing to do with the subject matter. My cursor rolled over the icon in the 3rd minute of the video.
Since I produced the series, I have learned to turn the Taskbar off to overcome confusion. At the moment, I am working on a new video that talks of turning an existing site into a PWA. I should have this finished over the next couple of days.
As far as registering the service worker, the following code will do that
if (‘serviceWorker’ in navigator) {
navigator.serviceWorker.register(‘sw.js’)
.then(reg => console.log(‘service worker registered’))
.catch(err => console.log(‘service worker not registered’, err));
}
If you place the above code in your page and have an empty sw.js
file, then, in the console, you will see