Open jedwards1211 opened 9 years ago
source-map-support tries to retrieve the source maps for those files that start with webpack://. Is there a way to retrieve the source map of those files or should source-map-support just ignore those files?
The purpose of source-map-support is to show errors with stack traces that refer to the code lines of the original file, not the transpiled file.
Yes, I've used source-map-support in other projects as well. There might be a way to retrieve those files, but I think it would make the most sense for it to just ignore them if it can't, right? I still don't completely understand how it would prevent an eval
containing a sourceMapURL
from running though.
How do you know that the error has anything to do with the eval source maps, you refer to? Can you give me an example? In the screenshot that you have posted in evanw/node-source-map-support#108 I just see that XMLHttpRequest throws an uncaught error because it cannot retrieve the file.
I haven't gotten to the root of the issue, but I know I can get it to work if I either
sanjo:jasmine
devtool: 'source-map'
in the webpack config, which outputs a separate source map file (instead of using devtool: 'eval'
which wraps the modules in eval
statements).sanjo:jasmine
+ devtool: 'source-map'
works, and devtool: 'eval'
without sanjo:jasmine
works.
So something about the combination of devtool: 'eval'
and sanjo:jasmine
makes the modules inside my webpack bundle fail to run, and I'm pretty sure it has to do with source-map-support. I'll let you know if I figure out more details.
And I've managed to work around this for now by only Velocity package tests, so that when I'm running in dev mode, it's not present and I can use devtool: 'eval'
.
Is there any major benefit of using devtool: 'eval'
over devtool: 'source-map'
? Meteor builds use separate source-map files.
The root cause may lie with the
source-map-support
npm package, but I'm unable to use velocity due to this, so I'm logging the issue here as well.See: https://github.com/evanw/node-source-map-support/issues/108