cloud9 을 통합환경으로 쓰고 있는데
syntax-highlighting만 겨우 지원하는 무거운 노트패드 같다.
의도와는 다르게 디버깅(watch, breakpoint 등)이 잘 돌아가지 않고 있다.
node-inspector 를 쓰면 좋다.
chrome 의 디버거와 거의 똑같이 생겨서 익숙하다.
먼저 설치
$ npm install node-inspector
실행해보자.
디버깅을 위한 거니까 server 기동도 디버그 모드로 띄운다.
$ node --debug server.js
그리고 inspector 를 띄운다.
$ node-inspector --web-port=3001
visit http://0.0.0.0:3001/debug?port=5858 to start debugging
친절하게 안내해준다.
디버그 포트는 기본이 5858 이니까 혹여 변경했다면 알아서 인자를 바꿔주자.

크고 아름답다.