[英]Error: react-native version in "package.json" doesn't match the installed version in "node_modules"
I ran react-native-git-upgrade
so I can run react-native run-android
later on to build my app on my device but an error message appeared.我运行了react-native-git-upgrade
所以我可以稍后运行react-native run-android
来在我的设备上构建我的应用程序,但出现了一条错误消息。
The error says:错误说:
Error: react-native version in "package.json" (https://github.com/expo/react-native/archive/sdk-31.0.0.tar.gz) doesn't match the installed version in "node_modules" (0.57.1).
I tried running 'npm install' again but the error still occurs.我再次尝试运行“npm install”,但仍然出现错误。
You are using Expo.您正在使用世博会。 You can't upgrade like this way.你不能这样升级。 Expo using custom version of React Native.Check this. Expo 使用自定义版本的 React Native。检查这个。 https://docs.expo.io/versions/latest/workflow/upgrading-expo-sdk-walkthrough https://docs.expo.io/versions/latest/workflow/upgrading-expo-sdk-walkthrough
and you are already using latest version of Expo.并且您已经在使用最新版本的 Expo。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.