I am using the ionic PWA Service worker. I got it to work nicely with one caveat. I can’t figure out how to notify the user that they are using an offline version and that the data may be stale
var url = req.url.replace(/#.*/, '#/offline');
return toolbox.cacheOnly(new Request(url), vals, opts);
which also didn’t work. I don’t need a seperate page I just want to be able to show the user an ionic popup saying that he is offline. Any help is greatly appreciated.
Thanks
You are correct, sorry, I missed that! I just saw the main point about using the Network plugin, I should have read it more thoroughly before commenting!
on the topic - I think still the problem for online/offline detection is a tough one since there is no one cross browser interface to do such detection. In y case I try to focus specific browsers and not to promise users that it will work across the board.