waitUntil/respondWith can be called inside a microtask during event dispatch.

To conform to the specification, ExtendableEvent.waitUntil() and FetchEvent.respondWith() can now be called during the microtask checkpoint at the end of event dispatch. Previously, this would throw an InvalidStateError.

Specification

Editor's draft

Status in Chromium

Blink>ServiceWorker


Enabled by default in:

  • Chrome for desktop release 75
  • Chrome for Android release 75
  • Android WebView release 75

Consensus & Standardization

After a feature ships in Chrome, the values listed here are not guaranteed to be up to date.

Owner

Last updated on 2019-04-16