I had the same problem and to solve that I edited this file:
my-domain.com/superpwa-sw.js
Replacing this block of code:
// Revving strategy
if ( e.request.mode === 'navigate' && navigator.onLine ) {
e.respondWith(
fetch(e.request).then(function(response) {
return caches.open(cacheName).then(function(cache) {
cache.put(e.request, response.clone());
return response;
});
})
);
return;
}
By this another block of code:
// Revving strategy
if ( e.request.mode === 'navigate' && navigator.onLine ) {
e.respondWith(
fetch(e.request).then(function(response) {
return caches.open(cacheName).then(function(cache) {
cache.put(e.request, response.clone());
return response;
});
}).catch(function( error ) {
console.log('There has been a problem with the "Revving strategy" operation: ' + error.message);
return caches.match(offlinePage);
})
);
return;
}
If you use the OneSignal integration you’ll need to edit this same block of code, but on the following path:
my-domain.com/OneSignalSDKWorker.js.php
If you want to understand what this block of code does, take a look at this commentary on GitHub: https://github.com/SuperPWA/Super-Progressive-Web-Apps/issues/36#issuecomment-388105238
I hope these informations help someone! ??
Kind regards,
Glauber Silva