<TouchableOpacity
style={styles.button}
onPress={() => {
navigation.reset({
index: 0,
routes: [{ name: 'ProfilePage' }],
});
}}
>
<Text style={styles.buttonText}>Test Navigation</Text>
</TouchableOpacity>
This code crashes my app whenever I click on the Test Navigation button. I've read on multiple posts on reddit, github and stackexchange that the fix is to install react-native-reanimated, and to add
import react-native-reanimated;
to the top of the App.js file. I did both those things and it doesn't work. I've got no clue what to do