Can I force a chrome tab to always be active?

Viewed 1995

So I'm having this issue where there's a tab which I want to be running permanently even if the tab isn't focused or minimized.

I've found that in chrome://discards/ I can see which tabs are active but what I want is a way to set the lifecycle state to be always active no matter what.

I've tried disabling the Automatic tab discarding flag and the throttling flag but neither of those worked for me.

1 Answers

Not a complete answer I'm afraid, but figured I'd share this on the off chance it's helpful after finding it in my own search. (and this question is still relevant to someone out there and finds this again like me)

https://developers.google.com/web/updates/2018/07/page-lifecycle-api#state-passive

this ^^^ seems to be something to look into (chrome basically assigns pages a "state" for whether the page should be active/frozen/etc based on current visibility and other events).

if you are the page's dev, and you want to passively force such to happen or NOT happen, this library might be what you need/want, but I have not tested this and it could just be for reading the current state rather then changing it (I don't know). https://github.com/GoogleChromeLabs/page-lifecycle/blob/master/README.md

So yeah, not a full answer since you as a user, don't seem to have the option to change it, which is weird.

Related