- mongodb - 在 MongoDB mapreduce 中,如何展平值对象?
- javascript - 对象传播与 Object.assign
- html - 输入类型 ="submit"Vs 按钮标签它们可以互换吗?
- sql - 使用 MongoDB 而不是 MS SQL Server 的优缺点
我尝试在 windows 环境下使用 node-inspector (v0.12.8)、nodejs (v5.9.1) 和 chrome (v49.0.2623.112 m) 调试我的 server.js 应用程序。
在shell中我做
node-inspector
Node Inspector v0.12.8 Visit http://127.0.0.1:8080/?port=5858 to start debugging.
在第二个 shell 中我会这样做
node --debug server.js
当我转到 chrome 标签时,我收到一条消息:
Detached from target
remote debug has been terminated with reason: websocket_closed
please reattach to the new target
在 chrome 的控制台开发工具中,我可以看到检查员找不到实验功能 canvasInspection 的消息(在最新的 chrome 版本中删除)。
我做错了什么?
最佳答案
不是具体的答案,但是从 Node v6 开始,您实际上可以在启动进程时只使用 --inspect
标志,它会让您使用 Chrome 调试工具而不是依赖在 Node 检查器上。看看吧:
https://nodejs.org/docs/latest/api/debugger.html#debugger_v8_inspector_integration_for_node_js
希望这会有所帮助!
关于node.js - 无法使用 Node 检查器 : websocket_closed and Assertion failed: Unknown experiment canvasInspection 调试 Nodejs,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36565449/
我知道在寻找解决方案时,这些是一些类似/重复的响应。但 Node 世界似乎更新得如此频繁,以至于我找到的任何答案都指的是更旧的版本。 我当前正在运行: Node v6.9.1 Node 检查器 v0.
我尝试在 windows 环境下使用 node-inspector (v0.12.8)、nodejs (v5.9.1) 和 chrome (v49.0.2623.112 m) 调试我的 server.
我是一名优秀的程序员,十分优秀!