node-inspector
:$ npm install -g node-inspector
配置gulp,gulp能夠用 gulp-node-inspector 或 用gulp-shell直接啓動node-inspector命令。css
gulp.task 'server',()-> nodemon({ nodeArgs: ['--debug'] #須要開啓調試 script: './server.coffee' ext: 'coffee css jade html json' ignore: ["assets/**/*", "public/**/*.*", "test/**/*"], }) #能夠設置調試端口,忽略文件(夾),調試模式,是否保存瀏覽試更改的內容,詳細應用可查看:https://www.npmjs.com/package/node-inspector gulp.task 'startDebug', shell.task ['node-inspector &'] gulp.task 'debug',["server"], ()-> gulp.start 'startDebug'
打開:http://127.0.0.1:8080/?port=5858 就能夠和前端代碼同樣調試了.html