Im trying to change the direction when opening a new screen but nothing works. Im trying both the native-stack and the non native stack. Just in case
import { createNativeStackNavigator } from '@react-navigation/native-stack';
const MyStack = () => {
...
return (
<Stack.Screen name="Tabs" options={({route}) => ({
headerShown: false,
})}>
{(props) => <MyTabs {...props} />} //MyTabs is a BottomTab navigator
</Stack.Screen>
<Stack.Screen
name="Settings"
options={{
headerShown: true, headerLeft: () => (
<Button
onPress={() => navigation.goBack()}
title="go back"
/>
),
gestureEnabled: true,
gestureDirection: 'vertical'
}}>
{(props) => <SettingsScreen {...props} />}
</Stack.Screen>
)
}
export const Navigator = () => {
<NavigationContainer>
<MyStack />
</NavigationContainer>
}