【发布时间】:2021-09-13 09:12:51
【问题描述】:
我认为这个问题是在我将项目推送到 github 之后出现的,我已经按照官方文档安装了,一切看起来都很好,但仍然。
我已经: - 使用 npm install @react-navigation/native 重新安装
-重新安装依赖项:expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-view
-删除 node_modules 然后 npm install
错误信息:
Unable to resolve module react-navigation from D:\Prog\Agora\Agora\node_modules\react-native-screens\src\createNativeStackNavigator.tsx: react-navigation could not be found within the project.
If you are sure the module exists, try these steps:
1. Clear watchman watches: watchman watch-del-all
2. Delete node_modules and run yarn install
3. Reset Metro's cache: yarn start --reset-cache
4. Remove the cache: rm -rf /tmp/metro-*
36 | NavigationAction,
37 | NavigationProp,
> 38 | } from 'react-navigation';
| ^
39 | import { NativeStackNavigationOptions as NativeStackNavigationOptionsV5 } from './native-stack/types';
40 | import { HeaderBackButton } from 'react-navigation-stack';
41 | import {
【问题讨论】:
标签: react-native