I want to perform two actions but it doesn't work.
const backAction = NavigationActions.back({
key: null
})
const dispatchLogoutAction = NavigationActions.reset({
index: 0,
actions: [NavigationActions.navigate({routeName: "LoginView"})]
});
nextProps.navigation.dispatch(backAction);
nextProps.navigation.dispatch(dispatchLogoutAction);
What other ways to dispatch both actions in react-navigation
rather than listing dispatch statements parallelly?