3

I'm running react-native app on windows using AVD. App is ruuning without errors. But When I'm trying to debug the app remotely, it is throwing me an error saying:

Unable to connect with remote debugger

unexpected end of stream on connection

enter image description here I set Debug server host & port for device to localhost:8081.

Whats going wrong?

5
  • did you start http://localhost:8081/ in web browser ? Commented May 3, 2019 at 7:19
  • @HardikVirani this normaly happens automaticly when you start debug mode Commented May 3, 2019 at 7:24
  • but sometime it will open with wrong url as well Commented May 3, 2019 at 7:29
  • did you use this link in google chrome : localhost:8081/debugger-ui Commented May 3, 2019 at 7:44
  • I tried, but no use Commented May 3, 2019 at 8:51

1 Answer 1

4

The simplest way of debugging code is to use Chrome. You don’t need to install any other apps. on Android emulator, or shake real devices, you will see the in-app developer menu. Tap “Debug JS Remotely”. The Chrome debugger will be opened automatically. You still need to open Developer Tools in Chrome manually. Open source files in the Sources tab, you can set breakpoints here. (Update on Feb 26, 2018: due to a bug in React Native Android, if the app says it failed to connect the debugger and the URL in Chrome is not

http://localhost:8081/debugger-ui/, change the URL to

http://localhost:8081/debugger-ui/, kill the app, and try again.)

All credit gose to this website : https://codeburst.io/react-native-debugging-tools-3a24e4e40e4

enter image description here

enter image description here

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.