4 ms·
This is a misconception. Service workers don't sit in the background consuming resources and performing arbitrary tasks. They respond to events, typically to in
by rictic 9y ago
This is a misconception. Service workers don't sit in the background consuming resources and performing arbitrary tasks. They respond to events, typically to intermediate requests while a user is using a site.
The service worker spec was carefully and deliberately designed to give the browser, not the site, control over resource consumption. The browser is allowed to stop any service worker at almost any time. See https://github.com/w3c/ServiceWorker/blob/master/implementation_considerations.md#event-driven-workers https://github.com/w3c/ServiceWorker/blob/master/implementat...