Answer the question
In order to leave comments, you need to log in
How to exclude modules from sourcemap in webpack 2?
Hello.
The project uses webpack 2 which bundles .js. Sourcemaps are generated during assembly:
// webpack.config.js
{
...
devtool: 'source-map',
...
plugins: [
new webpack.optimize.UglifyJsPlugin({
sourceMap: true
})
],
...
}
new webpack.optimize.UglifyJsPlugin({
sourceMap: true
sourceMapExclude: ['jquery', 'react', 'lodash', 'backbone']
})
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question