bug: Ionic 4 back button restart app (DOM) when you are in root [Cordova/App]
See original GitHub issueBug Report
Ionic version:
[x] 4.6.2 | 4.1
Current behavior:
the android back button reboots doom when it is in the last component
Gif Expected behavior: Close app
Steps to reproduce:
- Run ionic start “new project”
- Choose tab app
- run in android platform
Other information:
I noticed the error when I was developing my app and I stopped at the root page and press the button back. Apart from this, it is not detecting the backbutton subscribe Ionic info:
Ionic:
Ionic CLI : 5.0.1 (/usr/lib/node_modules/ionic)
Ionic Framework : @ionic/angular 4.6.2
@angular-devkit/build-angular : 0.13.9
@angular-devkit/schematics : 7.3.9
@angular/cli : 7.3.9
@ionic/angular-toolkit : 1.5.1
Cordova:
Cordova CLI : 9.0.0 (cordova-lib@9.0.1)
Cordova Platforms : android 8.0.0
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 4.0.1, (and 24 other plugins)
Utility:
cordova-res : not installed
native-run : 0.2.7
System:
Android SDK Tools : 26.1.1 (/home/juan/Android/Sdk)
NodeJS : v11.15.0 (/usr/bin/node)
npm : 6.10.0
OS : Linux 4.19
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:11 (5 by maintainers)
Top Results From Across the Web
bug: Ionic 4 back button restart app (DOM) when you ... - GitHub
Hi there. The hardware back button was not imported in the app.tsx after the minify with arrow functions. I`m providing a pull request....
Read more >bug in Ionic 4 back button restart app (DOM) when you are in ...
When user clicks over hardware back button of Android app built with Ionic 4. It just restart the without executing subscribed code. self....
Read more >Hardware Back Button for Capacitor & Cordova on Android ...
When running in a Capacitor or Cordova application, Ionic Framework will emit an ionBackButton event when a user presses the hardware back button....
Read more >How to Build Your First Ionic 6 App with API Calls
The service will take care of handling the API calls and simply return the data to our view later! Assets. This folder contains...
Read more >Mobile App Development with Ionic, Revised Edition
Cordova. 6. Prerequisites for Ionic Application Development ... The Ionic CLI has another very powerful feature that allows you to reload the app....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi @SidiBecker,
here is a little guide for you:
git clone https://github.com/ionic-team/ionic
orgit clone url-to-your-fork
and change the directory to the cloned repo (cd ionic
)git checkout v4.6.2
npm install
in the base directory of the cloned reponpm install
againnpm run-script build
Caution: Modifying your node_modules is a pretty dirty way and could result in other bugs/unexpected behaviors. I recommend you wait for the next offical release and just update your package.json reference of ionic.
Thank you so much @tntwist