[PWA] npm run build-prod fails (unmodified default)

I just gave the new 2.3.1 cli a spin and created a simple PWA (using some custom options - see screenshot).

I didn’t change anything code-wise.

npm start works fine, but
npm run build-prod throws an error and fails:

Hash: 36202f162d420f8eb83f
Version: webpack 4.32.2
Time: 13857ms
Built at: 2019-05-25 19:20:22
          Asset      Size  Chunks  Chunk Names
    css/app.css   348 KiB       0  main
css/app.css.map   523 KiB
      js/app.js   806 KiB       0  main
  js/app.js.map  2.65 MiB       0  main
Entrypoint main = css/app.css js/app.js js/app.js.map

ERROR in js/app.js from UglifyJs
`warnings` is not a supported option

Build failed with errors.

node 11.7.0
npm 6.9.0
MacOSX 10.14.5

Same thing when running without custom options:

In webpack.config remove this piece of code:

compress: {
  warnings: false,
},

Or update to latest CLI, it will use now Terser instead of UglifyJS for minifying

Worked! Thanks!

(although, when I tried, 2.3.1 was the latest version :wink:)