I am using only and only native-stack navigator, and now I am confused which libraries are required by react-native-screens/native-stack ?? I am asking this because, in react-navigation there is multiple libs to be install like:
react-native-gesture-handler
react-native-safe-area-context
@react-native-community/masked-view
So do I need the above 4 packages for only react-native-screens/native-stack ?
any help...
For native-stack, you should only need @react-navigation/native. You can read it at https://github.com/software-mansion/react-native-screens/tree/master/native-stack#native-stack-navigator. Does it solve your issue?
And reactnavigation.org says:
To finalize installation of react-native-gesture-handler, add the following at the top (make sure it's at the top and there's nothing else before it) of your entry file, such as index.js or App.js
import 'react-native-gesture-handler';
So we do we have to only react-native-gesture-handler ?
It is not needed for native-stack, but if you want it, you have to add it after installing the package.
@WoLewicki thank you very much, could you please let me know when it is needed react-native-gesture-handler ?
And also please if you know let me know do we need react-native-reanimated ? for native-stack animation?
It is needed when you want to use it in your project. As I said, native-stack does not require react-native-gesture-handler and react-native-reanimated. Animations are native there. You can check it by making a simple project without those libraries installed.
Thank you bro very much
No problem. Have a good day 馃檪 I am closing it then, feel free to comment if you have any questions.