React Native 版本不匹配 [英] React Native version mismatch
问题描述
当我初始化一个新项目然后启动 Xcode 模拟器时收到以下消息:
Getting the following message when I init a new project and then launch the Xcode emulator:
React-Native 版本不匹配
React-Native Version Mismatch
Javascript 版本 0.50.1原生版本:0.50.0
Javascript Version 0.50.1 Native version: 0.50.0
确保您已重建本机代码....
Make sure you have rebuilt the native code. ...
有谁知道这里发生了什么并且可以帮助我吗?
Does anyone know what is going on here and can help me?
推荐答案
这是我用它完成的:
关闭所有终端并再次运行构建.
Close all terminals and run build again.
你可能忘记关闭另一个项目的 nodejs 终端,而他们碰巧安装了不同的 React 版本.
You may forget to close nodejs terminal from another project, and they happen to have installed different react version.
因此从 nodejs 服务器获取的代码与本机服务器发生冲突.
So the code fetches from nodejs server conflicts with the native one.
这篇关于React Native 版本不匹配的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!