1
votes

I configured the coffeescript compiler to run map (-m) using IntelliJ with NodeJS. I assume with the source maps I should be able to debug in coffeescript files in Chrome developer tool. The enable souce map was checked. I tried to open any .coffee file but got the "Cannot GET /path.../foo.coffee" error. The folder of where the coffeescript files resides in the sources explorer was weird. ../../../../../Web/src/test/webapps/installManager

I think it reflects what's in the map.

"sourceRoot": "../../../../..",
"sources": [
   "Web/src/test/webapps/installManager/app.coffee"
],

I do have sourceMappingURL in my js files. /* //@ sourceMappingURL=Common.map */

The following is my configuration for running the Coffeescript compiler:

Application Parameters: -cwm /home/repository/svn/ding/Web/src/test/webapps

Why can't Chrome get the coffee file since that the maps are available now? Is it because of the path in the sourceRoot and sources in the maps?

I was able to add workspaces in Chrome canary and map them and even do the bidirectional editing but I still can't debug (can set breakpoints but the debugger never stopped at the breakpoints).

Thank you

1
I have the same problem with a twist: I can put break points in the files in the /scripts folder, but not in the /scripts/controllers. Weird - mfeingold

1 Answers

2
votes

I fixed my problems - it was all in the cross references between the js coffee and map files. As soon as I configured it so that the transpiled .js was placed right next to the coffee (and the map, it picked it up.