Closed stevies closed 7 years ago
Ah - I see it now:
ENV === 'test' || ENV === 'development' ?
envDev(ENV !== 'test' ? {} : {devtool: 'inline-source-map'}) :
should be:
ENV === 'test' || ENV === 'development' ?
envDev(ENV === 'test' ? {} : {devtool: 'inline-source-map'}) :
Turn on source maps for development, not for test.
Actually no, the behavior is correct. inline-source-map
has to be used for test
because of coverage reporting. Putting {}
doesn't disable the devtool, just uses the default one (see the related easy-webpack). But it might be that the default sourcemap tool doesn't work in your browser. Both Chrome and FF has an issue with one or another I think, so it's hard to get it working consistently across browsers.
I'd love a pull request to easy-webpack with a better default, if you can find out which one works best.
New skeletons should have solved this.
I'm submitting a feature request
When running webpack skeleton in development mode, there are no sourcemaps, so code breakpoints or debugger statements don't work.
Old skeleton had
entries in the webpack.config.js files. Not sure how to add similar to the new webpack.config.babel.js file to turn on the sourcemaps.