You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently this article recommends using the unload event to close popups and send stats. unload cannot be relied upon and best practice is to avoid it entirely, using pagehide or visibilitychange.
E.g. popups should be closed in pagehide, not unload because a page that canenter BFCache will not fire unload but will fire pagehide
Stats should not be sent from unload because if the page goes into BFCache and the user never returns, the unload event will never fire.
The text was updated successfully, but these errors were encountered:
Currently this article recommends using the
unload
event to close popups and send stats.unload
cannot be relied upon and best practice is to avoid it entirely, usingpagehide
orvisibilitychange
.E.g. popups should be closed in
pagehide
, notunload
because a page that canenter BFCache will not fireunload
but will firepagehide
Stats should not be sent from
unload
because if the page goes into BFCache and the user never returns, the unload event will never fire.The text was updated successfully, but these errors were encountered: