【问题标题】:No option of debug JS remotely on Android simulator在 Android 模拟器上没有远程调试 JS 的选项
【发布时间】:2020-05-24 06:02:40
【问题描述】:

我正在使用 android 8.1 模拟器在 Win10 上使用 VS 代码调试我的 React Native (0.62) 应用程序。使用react-native run-android 启动应用程序后,Ctrl+m 调出开发菜单:

但是菜单中没有Debug JS remotely的选项。如何调出Debug JS Remotely的选项?

【问题讨论】:

    标签: android react-native android-studio


    【解决方案1】:

    您应该能够在 Chrome 开发工具中调试 RN 应用程序,除非您正在运行生产版本。 如果你想use another debugger,你可以用REACT_DEBUGGER env 设置它。多变的。示例:

    REACT_DEBUGGER="node /path/to/launchDebugger.js --port 2345 --type ReactNative"
    

    对于 VSCode,有 this extension。有一个section 解释如何调试。

    【讨论】:

      猜你喜欢
      • 2018-06-20
      • 2010-12-17
      • 1970-01-01
      • 1970-01-01
      • 2019-01-30
      • 2016-02-21
      • 1970-01-01
      • 2016-12-21
      • 2021-03-19
      相关资源
      最近更新 更多