From:  Bryce Cronkite-Ratcliff <>
Date:  23 Jan 2015 07:47:33 Hong Kong Time

Using SourceMap/X-SourceMap HTTP header


Hi folks,

I'm trying to use the http header to set the location of the sourcemaps for
code I am serving.

Neither firefox (developer edition 37) or chrome (v40) are responding to
the requests, as in, I see no network activity in the network tabs of each
browser's respective devtools that is attempting to fetch the sourcemaps.

I've tried setting SourceMap, X-SourceMap, and both together, setting as
the header value either an absolute URL or script-origin relative URI. I
have also tried changing the content-type of the response from
application/json to text/javascript to application/javascript and
application/x-javascript .

The //# sourceMappingUrl comment works as advertised and I see sourcemaps
retrieved right and left as well as related network requests.

I would prefer to use the HTTP header but I am not sure how to proceed.

Thank you!