【问题标题】:React native debug on windows在 Windows 上进行本机调试
【发布时间】:2017-01-18 19:31:44
【问题描述】:

我有一个 react native android 应用程序,我目前正在使用 android 模拟器 在 windows 机器上进行调试。

我可以打http://localhost:8081/debugger-ui

它告诉我

React Native JS code runs inside this Chrome tab.

Press ⌘⌥J to open Developer Tools. Enable Pause On Caught Exceptions for a better debugging experience.

Status: Waiting, press ⌘R in simulator to reload and connect.

当我打开 chrome 开发人员工具时,我没有看到我的反应代码被加载到该选项卡的“源”中。

所以我的问题是,我如何才能让我的手机将反应内容加载到 chrome 标签中?我希望至少能在我的 chrome 开发者工具中看到 console.log 的内容。

【问题讨论】:

    标签: debugging reactjs react-native


    【解决方案1】:

    好的。找到要做什么:

    1. Ctrl + M 打开一些“开发者菜单”
    2. 点击开启远程JS调试
    3. 根据您的 react native 版本,chrome 可能会也可能不会打开调试选项卡。但无论如何,去 localhost:8081/debugger-ui 应该就可以了。

    【讨论】:

    • 哇,这么多东西我都在挣扎,谢谢你的 Ctrl + M 东西!我正在使用 Genymotion 并且 Ctrl + M 在 Genymotion 中也可以使用!
    • =D 很高兴我能帮上忙。
    • 谢谢兄弟,我也可以按照你的步骤 3 使用 Firefox,我只是在 Firefox 中导航到 localhost:8081/debugger-ui 。
    • 终于有正确答案了
    猜你喜欢
    • 2017-10-20
    • 2018-03-21
    • 1970-01-01
    • 2010-10-05
    • 1970-01-01
    • 2018-12-29
    • 2020-09-25
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多