1.npm install -g node-inspector
2.node-inspector安装完成以后运行如下指令启动node-inspector

3.到需要调试文件所在的路径下执行如下指令:node --debug-brk test.js(需要新建个控制台)

4.打开chrome浏览器 输入http://127.0.0.1:8080/?port=5858,找到对应的文件 就可以开始断点调试啦

1.npm install -g node-inspector
2.node-inspector安装完成以后运行如下指令启动node-inspector
3.到需要调试文件所在的路径下执行如下指令:node --debug-brk test.js(需要新建个控制台)
4.打开chrome浏览器 输入http://127.0.0.1:8080/?port=5858,找到对应的文件 就可以开始断点调试啦
本文标题:使用node-inspector调试NodeJS代码
本文链接:https://www.haomeiwen.com/subject/ycqewttx.html
网友评论