We want to make a website available offline, we started with App Cache but found this has been discontinued with Service Worker.
I found some help on setting up a service worker on a test site I created however it still does not seem to work. It registers the service worker etc but doesn't seem to cache anything.
Here is they code for the service worker js. Any ideas?
screenshot of js code