1

No matter if I choose "Attach to packager" configuration running packager with

react-native start

first or "Debug Android", breakpoints that I set in vs code are greyed out and are not get hit.

greyed out breakpoint Here is information I am getting from Debug Console:

OS: win32 ia32 Adapter node: v7.9.0 ia32 vscode-chrome-debug-core: 3.23.0 Starting debugger app worker. Established a connection with the Proxy (Packager) to the React Native application Debugger worker loaded runtime on port 10029 Running application "EugeneKrApp" with appParams: {"rootTag":71}. DEV === true, development-level warning are ON, performance optimizations are OFF index.bundle:19019 Warning: componentWillMount is deprecated and will be removed in the next major version. Use componentDidMount instead. As a temporary workaround, you can rename to UNSAFE_componentWill

There is a bunch of warnings down the line like the last one about componentDidMount which I didn't include, they hardly influence debugging.

eugenekr
  • 6,260
  • 3
  • 21
  • 26

1 Answers1

0

I had the same problem. It was due to the fact that 'Debug JS Remotely' was not enabled on the device/emulator.

Please check Tunvir Rahman Tusher answer and comments on this question.

Enter 'adb shell input keyevent 82' in the cmd/bash on your dev machine while the app is open on the device/emulator. A dialog box opens on the device/emulator like

enter image description here

Select 'Debug JS Remotely' and it will work out. You might need to restart the debugger.

akhalid7
  • 61
  • 2
  • 4