T
T
Torento203452021-08-18 08:50:53
webpack
Torento20345, 2021-08-18 08:50:53

Why isn't Uglify working?

Outputs the code simply assembled into one file without compression

const UglifyJsPlugin = require('uglifyjs-webpack-plugin');

module.exports = {
  entry: {app: './js/index.js'}
  output: {
    filename: '[name].js',
    path: path.resolve(__dirname, './dev/js')
  },
   optimization: {
    minimizer: [new UglifyJsPlugin()],
  },
}

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question