March 28th, 2020
Sure. Fire away.
return part still happens first though. The
waitUntil ensures that the service worker doesn’t “hang up” while you’re getting the fresh version from the network, but while that’s happening, the user has been served the cached file. adactio.com/notes/16636
They’re both asynchronous actions—using
cache and using
waitUntil ensures that when one of them is done, the other still carries on. It doesn’t mean that one waits until the other is done. adactio.com/notes/16637
Ah! Got it now! (I think I also confused it with the drawback of this method jakearchibald.com/2014/offline-c…) Thanks for clarifying, that is awesome! All the best for you and your family, stay healthy!