erwan erwan - 1 year ago 107
Android Question

Handling back button in React Native, Navigator on Android

I have a

in an Android react native application.

I'm using
to navigate to a different page. It would seem natural that the back button would pop the navigator and to go back one page, but that's not what's happening (it quits the app).

Do the react-native
really has no back button support, do I need to plug it myself with a

Answer Source

Yes, you have to handle the back button yourself. I think the main reason for this is you may want to do different things with the back button instead of just moving back through the stack. I don't know if there are plans to incorporate back button functionality in the future though.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download