I think the problem is because you are testing it using ionic serve, try to add browser platform to your project then run ionic cordova run browser then test it
How to add the browser platform?
ionic cordova platform add browser
AddEventListener will only work with InAppBrowser. So you need to use the “_blank” as the target.
let browser=open(url, "_blank", "location=true");