onSuspend property
EventStream<void>
get
onSuspend
Sent to the event page just before it is unloaded. This gives the extension opportunity to do some clean up. Note that since the page is unloading, any asynchronous operations started while handling this event are not guaranteed to complete. If more activity for the event page occurs before it gets unloaded the onSuspendCanceled event will be sent and the page won't be unloaded.
Implementation
EventStream<void> get onSuspend =>
$js.chrome.runtime.onSuspend.asStream(($c) => () {
return $c(null);
}.toJS);