Quantcast
Channel: Active questions tagged react-native+typescript - Stack Overflow
Viewing all articles
Browse latest Browse all 6287

Functional components as screens goBack() wont reset screen

$
0
0

I am using functional components as screen with typescript.

When I navigate from screen A to B and call goBack() it navigate back to A but when I navigate again to B it does not reload

I don't want to use on focus reload.

type RooList={  Home: undefined;  PageOne: undefined;  PageTwo: undefined;}type AppProps = {  navigation: StackNavigationProp<RooList>;  route: any};navigation.goBack()  does not reset

When I call

navigation.pop(1), navigation.replace()

I get following error

navigation.pop is not a function/undefined


Viewing all articles
Browse latest Browse all 6287

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>