[whatwg] onclose events for MessagePort

Jonas Sicking jonas at sicking.cc
Tue Oct 22 08:23:56 PDT 2013


On Oct 21, 2013 6:06 PM, "Ehsan Akhgari" <ehsan at mozilla.com> wrote:
>> We could further define that "channeldropped" is fired when the owner
>> of the *other side* is navigated away from. This would mean that
>> events can be received even after a "channeldropped" event has been
>> fired since other windows could still hold a reference to the port and
>> send messages through it. However it would allow us to release the
>> strong reference that the "channeldropped" event listener implicitly
>> creates as soon as either side is navigated away from.
>
> But what if the page is navigated back to?  I think this implies that
having fired a "channeldropped" event because of this reason means that the
UA needs to make it impossible to navigate back to the same window, which
means disabling optimizations such as Gecko's back-forward cache, which
sucks.

We could define that it is not automatically sent until the page is kicked
out of the bfcache.

But yeah, that maight make this behavior unreliable enough that it's not
worth doing.

/ Jonas



More information about the whatwg mailing list