终极使用方法:

  1. https://gitee.com/zhenghuazhi/javafx-WebView-Debugger 进入页面
  2. 下载项目
  3. 将libs的目录放在自己的项目中
    在这里插入图片描述
  4. 在代码中加入
  DevToolsDebuggerServer.startDebugServer(webView.getEngine().impl_getDebugger(), 51742);
  1. 启动后会出现提示To debug open chrome and load next url: chrome-devtools://devtools/bundled/inspector.html?ws=localhost:51742/,由于谷歌已经改了参数,因此,这里需要在google浏览器上使用如下地址
devtools://devtools/bundled/inspector.html?ws=localhost:51742/
  1. 效果
    在这里插入图片描述
    在这里插入图片描述
Logo

技术共进,成长同行——讯飞AI开发者社区

更多推荐