If the user is online, then I want to unregister the service worker and then register it. That way they'll be using the latest version of the page while online and it will work if they're offline too.
m
mistersender
06/21/2022, 5:59 PM
I can't recommend enough not using service workers. it's caching hell
it's very, very possible to get into an un-updatable state
(that being said, there are some things service workers are fine for, but like... omg. SW are a nightmare)