0

I'm trying to debug some JavaScript built with closure compiler, running Chrome (54 stable) on Ubuntu.

I have my minified JavaScript file foo.js (loaded from a shell .html file) as well as a sourcemap file foo.sourcemap, and I'm serving them both on localhost using a simple python httpserver:

python -m SimpleHTTPServer 8000

foo.js ends with:

//# sourceMappingURL=/foo.sourcemap

I've verified that the 'use javascript sourcemap' setting is turned on.

However, I can see from the server logs that foo.sourcemap is never even requested from Chrome. What other things could I be missing which would cause the sourcemap file not to be loaded at all? I'm unsure how to debug from here.

Heretic Monkey
  • 11,687
  • 7
  • 53
  • 122
Gregable
  • 523
  • 4
  • 10

1 Answers1

0

Apparently the syntax for sourcemap comments has changed. Modifying this to:

//@ sourceMappingURL=/foo.sourcemap

Did the trick

Heretic Monkey
  • 11,687
  • 7
  • 53
  • 122
Gregable
  • 523
  • 4
  • 10