Search code examples
service-workerfetch-apiservice-worker-events

Can Service Worker or FetchEvent Detect or Listen for "stop" events?


Can a Service Worker or FetchEvent detect when a "stop" event is triggered by the user? For example, users could stop the page from loading images with the browser's stop button is clicked (or with window.stop() JavaScript). I would like my Service Worker to detect that event.


Solution

  • No, that's not something that's exposed to the service worker as an event.

    If you believe that it should be, filing a feature request against the specification would be the right first step.