I need to know when the crossrider's extension closes so I can throw some message in the background. It was easy on the other way around
appAPI.ready(function() {
}
This is what I'm using on popup.html to determine if the extension is opened. So what I need is something like appAPI.close(function() {}) but I can't find it on the Crossrider's doc http://docs.crossrider.com/
So if you want to monitor "popup page close" event, just listen to
unloadevent for popup page.Please be aware you can't use
console.login the function, since by the time the unload event fires it is already too late. See this post for more details.