Closed ghost closed 5 years ago
This is related to Cordova Plugin InAppBrowser and not ionic
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.
Ionic version: (check one with "x") (For Ionic 1.x issues, please use https://github.com/ionic-team/ionic-v1) [ ] 2.x [x ] 3.x [ ] 4.x
I'm submitting a ... (check one with "x") [x ] bug report [ ] feature request
Current behavior:
In my application I have a setInterval service running on the first page, and it increments a counter every second so I can verify its operation. The second page has buttons to try InAppBrowser with _blank and _self. Another button shows the counter. It keeps incrementing when using _blank but it does not increment while using _self. Once I exit the InAppBrowser the counter resumes incrementing.
Expected behavior:
The counter would continue incrementing when _self is used.
Steps to reproduce:
This is the code for invoking InAppBrowser: inAppBrowser.create(url,'_self'); Here is the service provide incrementer: var id = setInterval(function(){ i++; localStorage.setItem('closeViewerFlag', i); }, 1000);
Related code:
Other information:
It appears that I am not the only one having a problem with service providers when specifying "_self" for InAppBrowser. Here are the related forum topics: InAppBrowser Can’t Subscribe to Event, Nov 2016 InAppBrowser “loadstart” event trigger issue, Aug 2017 InAppBrowser executeScript not working, Apr 2017
Ionic info: (run
ionic info
from a terminal/cmd prompt and paste output below):