Hardware/software back button press ignored by ScreenStack and onDismiss
See original GitHub issueI’m trying to make some simple navigation components, but when I tried making a stack, it ignores the back press and shuts down the app instead of poping the screen.
<ScreenStack
style={{
flex: 1
}}
>
<Screen
style={StyleSheet.absoluteFill}
onDismissed={() => {console.log("------------ dismissed")}}
>
<Screen1/>
</Screen>
<Screen
style={StyleSheet.absoluteFill}
onDismissed={() => {console.log("------------ dismissed")}}
>
<Screen2/>
</Screen>
</ScreenStack>
Also the parameter is different for the example and documentation (docs say onDismiss, example has onDismissed. tried both and neither work)
I’d like to know if this is a bug or if I’m doing something wrong.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Preventing hardware back button android for React Native
I disable my back button (android) for whole application by add this code in ... Disable back button for module react-navigation, use hook...
Read more >Kivy Latest | PDF | Mac Os X Snow Leopard | Shader - Scribd
Then, you can execute application by doing a right click on the .py le ... We extend the build() function to be able...
Read more >Hardware Back Button for Capacitor & Cordova on Android ...
By default in Ionic, when the back button is pressed, the current view will be popped off the navigation stack, and the previous...
Read more >Preventing going back - React Navigation
The user pressed back button on a screen in a stack. The user performed a swipe back gesture. Some action such as pop...
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 FreeTop 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
Top GitHub Comments
@WoLewicki yup, it works now
@WoLewicki I’ll try (just don’t have a pc now, gonna be durring the weekend)