I'm trying to find a bug in my code but after so much time I feel hopeless. Could you help me, please?
import React, {useState, useRef, useEffect} from 'react';
import SickList from './pages/SickList'
import { NavigationContainer } from '@react-navigation/native';
import { createStackNavigator } from '@react-navigation/stack';
const App = () => {
const Stack = createStackNavigator();
const Menu = () => {
return(
<Stack.Navigator>
<Stack.Screen name="Home" component={SickList} />
</Stack.Navigator>)
}
return (
<NavigationContainer>
<Menu />
</NavigationContainer>
)
}
export default App;
Well, after some hours of trying to find out the reason, I tried to change package.json:
I changed to "react-native": "~0.63.4", "@react-navigation/stack": "^5.14.4", and it worked.