Does Firefox extends events page lifetime when I run a `fetch`?

Actually, does Chrome?
Or only internal API counts?
Looking at the docs: https://developer.chrome.com/docs/extensions/develop/concepts/service-workers/lifecycle#idle-shutdown

Events and calls to extension APIs reset these timers, and if the service worker has gone dormant, an incoming event will revive them.

MDN doesn’t mention (at least I can’t see it) what will prevent killing event page: https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/Background_scripts

No, not in Chrome: https://issues.chromium.org/issues/40827026

Not in Firefox, either, it looks like… You can use this line of code to test (run it slightly before the event page stops):

let response = await fetch(‘https://example.com:81/’).catch((e) => console.log(e));

1 Like