react-native中的“不存在捆绑包URL"是什么意思? [英] What is the meaning of 'No bundle URL present' in react-native?

查看:157
本文介绍了react-native中的“不存在捆绑包URL"是什么意思?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我运行一个本机项目时,出现错误no bundle URL present,但是我不知道自己犯了什么错误,我感到非常困惑.

解决方案

我也遇到了这个问题(第一次使用React Native入门).当-在运行ios仿真(react-native run-ios)时-我先运行npm install然后又运行react-native run-ios时,问题消失了.在终端窗口中,它表明正在捆绑,然后模拟器显示了欢迎屏幕.

react-native init PropertyFinder行尝试使用npm start(这对我有用)

================================================ ========================

更新16.9

我的端口8081被McAfee阻止了.直接使用其他端口不起作用react-native start --port=8082react-native run-ios --port=8082

尝试了这里给出的几乎所有解决方案.但是什么都没用.

        "react": "16.9.0",
        "react-dom": "^16.12.0",
        "react-native": "0.61.5",

解决方案:

在Xcode中搜索8081,并将其全部替换为8082.然后运行相同的命令来构建和运行该应用程序.应用程序运行正常

react-native start --port=8082
react-native run-ios --port=8082

When I run a react-native project, I get a error no bundle URL present , but I don't know what mistakes I do, I was very confused.

解决方案

I just ran into this problem as well (first time getting started with React Native). The problem disappeared when - while an ios simulation(react-native run-ios) was running - I ran npm install and then react-native run-ios again. In the terminal window, it showed that it was bundling, and then the simulator showed the welcome screen.

Check this link for briefs after react-native init PropertyFinder line try to use npm start (This one works for me)

========================================================================

UPDATE for 16.9

My port 8081 was blocked by McAfee. Using a different port directly wasn't working react-native start --port=8082 and react-native run-ios --port=8082

Tried almost all solutions given here. but anything didn't work.

        "react": "16.9.0",
        "react-dom": "^16.12.0",
        "react-native": "0.61.5",

Solution:

Searched for 8081 in Xcode and replaced all of them with 8082. Then run the same commands to build and run the app. App works smoothly

react-native start --port=8082
react-native run-ios --port=8082

这篇关于react-native中的“不存在捆绑包URL"是什么意思?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆