I cannot shut down the app I develop and deploy with Expo. I want my app to shut down on back button, or at least on home button, but it just goes to background. (This is maybe a react-native issue)
BackHandler.exitApp() does the same thing.
How to shut down the app and not just put it to background?
Just FYI - my understanding is that Apple and Google in general don’t advise that you explicitly kill apps. If it’s to save battery, you might want to just shutdown the parts of your app that are doing background stuff.
In the past I’ve gotten guidance from google that yes, the user shouldn’t think about “quitting” the way they do with a desktop app.
Also note that the OS (on either platform) might kill your app at almost any time if it’s in the background if the system needs the resources it’s taking.
Cool. Than on app going to background I need to restart what is needed to get on the initial state, so when the user reopens it has the app as it oppened it first time.