【发布时间】:2020-11-28 14:46:29
【问题描述】:
【问题讨论】:
标签: javascript react-native expo
【问题讨论】:
标签: javascript react-native expo
这是因为您安装的某些软件包与当前版本的 Expo
不匹配在您的终端中,您会看到类似的警告
要解决此问题,您必须通过运行此命令根据当前 expo 版本更新所有包
expo install packageName@packageVersion // expo install expo-av@8.2.1
【讨论】:
关闭您的 IDE。重新启动您的计算机。
打开您的项目,重新安装您的软件包 (npm install)。
重新运行您的项目 (react-native run-android )
【讨论】:
这是库版本问题。 不要使用'yarn add react-native-gesture-handler react-native-reanimated' 它将添加 react-native-reanimated@1.13.0 react-native-gesture-handler@1.7.0
使用'expo install react-native-gesture-handler react-native-reanimated' 它将添加 react-native-gesture-handler@~1.6.0 react-native-reanimated@~1.9.0
【讨论】:
几天前遇到这个错误,我可以通过运行来修复它:
expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-view
【讨论】:
expo start -c 清除了 expo 缓存,并通过打开模拟器 Device > Erase All Content and Settings 清除了我的 iOS 设备上的缓存。像魅力一样工作。