问题
I generate source maps for javascript files during minification. The map files are referenced using a relative URL from the minified JS files that sit next to the map files. Here is an example comment at the end of app-e47a6637.js
:
//# sourceMappingURL=app-e47a6637.js.map
The source map resolution works as expected in Firefox. However, Chrome does not load the map files.
Additional information:
- JS source maps are of course enabled in the settings.
- I tried putting a proxy between Chrome and the server. Chrome does not even request the map files.
- I use
gulp-sourcemaps
to generate the map files. - I don't want to use the workspace feature of Chrome. I just want it to display the original source files.
How can I enable source maps in Chrome?
来源:https://stackoverflow.com/questions/34138737/debug-source-maps-loading-on-chrome