Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ionic 4 hardware back button issue #20210

Closed
imeeran opened this issue Jan 15, 2020 · 2 comments
Closed

Ionic 4 hardware back button issue #20210

imeeran opened this issue Jan 15, 2020 · 2 comments
Labels

Comments

@imeeran
Copy link

imeeran commented Jan 15, 2020

Hardware back button is not working without this code, code is given below.

  this.platform.backButton.subscribeWithPriority(0, () => {
    if (this.routerOutlet && this.routerOutlet.canGoBack()) {
      // this.routerOutlet.pop();
    } else if (this.router.url === '/home') {
      // this.platform.exitApp(); 

      // or if that doesn't work, try
      navigator['app'].exitApp();
    } else {
      
      this.confirm();
    }
  });

Is this issue solved or not yet? Can anyone give me any update on this issue? or suggest me a perfect way to solve that.
Thanx in advance.

@ionitron-bot ionitron-bot bot added the triage label Jan 15, 2020
@liamdebeasi
Copy link
Contributor

Thanks for the issue. I am going to close this as a duplicate of #17824. There are some known issues with the hardware back button which we are tracking in #16611.

@ionitron-bot
Copy link

ionitron-bot bot commented Feb 14, 2020

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.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Feb 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants