When I upgraded Webpack from v3 to v4, I got a bunch of errors. I already get used to encountering the errors when I upgrade the Webpack, sigh…?
The first 2 errors I encountered were
Error: webpack.optimize.CommonsChunkPlugin has been removed, please use config.optimization.splitChunks instead. ... Error: webpack.optimize.UglifyJsPlugin has been removed, please use config.optimization.minimize instead.