React-native 无法连接到 Android 设备上的开发服务器 [英] React-native Could not connect to Development Server on android device

查看:110
本文介绍了React-native 无法连接到 Android 设备上的开发服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

设备已连接,Package Server 正在运行,端口 8081 出现问题,

Device is connected, Package Server is running, there was issue of port 8081,

这就是我使用 react-native run-androidreact-native start --port 8089 开始的原因.

That's why I started this using react-native run-android and react-native start --port 8089.

但仍然无法运行我的第一个应用程序请帮忙,提前致谢:)

But still unable to run my first app please help, thanks in advance :)

推荐答案

如果你运行 react-native start 后有虚拟设备打开一个新终端并转到您的应用程序目录并键入 adb connect 127.0.0.1:62001 然后键入 adb devices现在你应该看到你的设备之后转到您的模拟器或真实设备并摇动它(在虚拟设备中ctrl + 0)并转到开发设置和......

if you have a virtual device after you run react-native start open a new terminal and go to your app directory and type adb connect 127.0.0.1:62001 then type adb devices now you should see your device after that go to your emulator or real device and shake it(in vitual device ctrl+0) and go to dev setting and ............

这篇关于React-native 无法连接到 Android 设备上的开发服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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