0

Im currently doing a course in udemy about react-native and one of the contents requires me to install react-native-screens and react-native-safe-area-context. However when installing "npm install @react-navigation/stack" and run the app (metro) i get this error :

enter image description here

Is there any fix? thanks

1
  • Can you paste the first few lines of your MainActivity.java?
    – Abe
    Commented Dec 29, 2021 at 20:59

1 Answer 1

1

You can follow react-navigation documentation(react navigation). Also, ensure that you have installed the required libraries.

yarn add @react-navigation/native react-native-screens react-native-safe-area-context

If you have npm use this:

npm install -save @react-navigation/native react-native-screens react-native-safe-area-context

Install above libraries and then install stack navigation.

yarn add @react-navigation/stack

for npm:

npm install --save @react-navigation/stack

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.