Let's pretend the Chromium team come around and we get some way of maintaining a persistent connection like a Websocket in a service worker / something else analogous to a background script.
I'd like to be able to leverage WebRTC in the background - not for media streams, but for peer to peer data communication. Service workers don't have access to the browser-provided Window, so can't easily create their own RTCPeerConnections.
It's looking like this isn't an option, but just in case, does anyone know a way to get a working RTCPeerConnection in a service worker? Make one in a content script and pass it in somehow, perhaps?
Otherwise, I suppose I'm looking at having the extension maintain a permanently pinned tab, which isn't going to be a great experience but might work for now.