**我正在使用 0.64.1 版本开发 React Native 项目。我尝试升级到版本 0.74.0 但没有成功。因此,我决定恢复到原始版本 0.64.1,并隐藏所有更改。
但是,在存储更改并运行常用命令来启动项目后,我遇到了错误。 ** 错误:
**Require cycles are allowed, but can result in uninitialized values. Consider refactoring to remove the need for a cycle.
ERROR ReferenceError: Property 'BigInt' doesn't exist, js engine: hermes
ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.
This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native., js engine: hermes
ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.
This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native., js engine: hermes**
节点:14.15.4 国家PM:2010年14月6日 JDK:11.0.23
为了解决此问题,我尝试了以下步骤:
-删除了项目并克隆了一个新副本,但出现了同样的错误。 -删除了项目和Android Studio,然后克隆了一个新副本,但同样的错误仍然存在。 - 运行各种命令来解决该错误,但没有成功。 -重置我的笔记本电脑并从头开始重新设置所有内容,但我仍然遇到相同的错误。
由于你已经全局安装了react native,我建议你使用以下方法删除:
卸载后,在工作目录中本地安装react-native。使用
npm install react-native@<your_version>