You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's a common practice to ask users to click an "refresh" or "update" button when a new Service Worker is waiting. The normal way to actually kick off the update is to post a message to the Service Worker, arranging a convention under which the SW can call skipWaiting() in the Service Worker's own scope.
It would be convenient if the ServiceWorker object returned by ServiceWorkerRegistration.waiting had a skipWaiting() method, so developers wouldn't have to configure a message listener at all. Combined with #1222, you could write code like this:
It's a common practice to ask users to click an "refresh" or "update" button when a new Service Worker is waiting. The normal way to actually kick off the update is to post a message to the Service Worker, arranging a convention under which the SW can call
skipWaiting()
in the Service Worker's own scope.It would be convenient if the ServiceWorker object returned by ServiceWorkerRegistration.waiting had a
skipWaiting()
method, so developers wouldn't have to configure a message listener at all. Combined with #1222, you could write code like this:(Uh, don't actually use
confirm()
in production; it's just convenient for this example.)The text was updated successfully, but these errors were encountered: