使用node-inspector调试的时候,提示下面的异常,我的node版本是6.9.2出现下面的异常,我同事的版本4.2.1就没有这个问题。
C:Usersdzm>node-inspector --web-port=8888
Node Inspector v0.12.8
Visit http://127.0.0.1:8888/?port=5858 to start debugging.
C:UsersdzmAppDataRoaming
pm
ode_modules
ode-inspectorlibInjectorClient.
js:111
cb(error, NM[0].ref);
^
TypeError: Cannot read property 'ref' of undefined
at InjectorClient.<anonymous> (C:UsersdzmAppDataRoaming
pm
ode_modules
ode-inspectorlibInjectorClient.js:111:22)
at C:UsersdzmAppDataRoaming
pm
ode_modules
ode-inspectorlibDebugger
Client.js:121:7
at Object.value (C:UsersdzmAppDataRoaming
pm
ode_modules
ode-inspecto
rlibcallback.js:23:20)
at Debugger._processResponse (C:UsersdzmAppDataRoaming
pm
ode_modules
node-inspectorlibdebugger.js:95:21)
at Protocol.execute (_debugger.js:121:14)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at readableAddChunk (_stream_readable.js:176:18)
at Socket.Readable.push (_stream_readable.js:134:10)
at TCP.onread (net.js:548:20)
解决办法是找到C:UsersdzmAppDataRoaming
pm
ode_modules
ode-inspectorlibInjectorClient.
的第111行,修改如下:
js