Debugging CoffeeScript with the Node Inspector Debugger
For what it’s worth, since we announced the availability of Node Inspector v0.7 last week, we got a few questions about whether or not you could use Node Inspector to debug CoffeeScript. The good news is, yes, you can!
Getting started is straight-forward, just make sure to
generate source-maps when compiling
your CoffeeScript sources to JavaScript by adding -m
option.
For example:
coffee -c -m *.coffee
node-debug app.js
For Grunt users, the plugin
grunt-contrib-coffee has an
option named sourceMap
.
Node Inspector supports source-maps out of the box, so no extra configuration is needed.
Originally published at https://strongloop.com/strongblog/debug-coffeescript-node-js-inspector/