Closed niftylettuce closed 7 years ago
Got a button, click it, runs this func
_handleLogout = () => { const { setUser } = this.context; setUser(); this.props.navigation.getNavigator('drawer').toggleDrawer(); this.props.navigation.getNavigator('drawer').immediatelyResetRouteStack( [ Router.getRoute('drawer') ], 0 ); this.props.navigation.getNavigator('master').immediatelyResetRouteStack( [ Router.getRoute('map') ], 0 ); Alert.alert('Logout', 'You have successfully logged out'); };
Okay so it doesn't work, error screenshot below.
Basically I just want to reset the stacks of the navigators for both drawer and the main master one for my views. Looked elsewhere, saw nothing. Readme isn't documented on this usage really.
looks like my var is undefined, let me check more..
TYPO immediatelyResetRouteStack -> immediatelyResetStack
immediatelyResetRouteStack
immediatelyResetStack
Got a button, click it, runs this func
Okay so it doesn't work, error screenshot below.
Basically I just want to reset the stacks of the navigators for both drawer and the main master one for my views. Looked elsewhere, saw nothing. Readme isn't documented on this usage really.