TerserPlugin 비슷한 기능
uglifyJSWebpackPlugin 개발자들이 해당 플러그인을 더 이상 유지보수를 진행하지 않고 있는 반면, TerserPlugin은 계속 진행
, minify 속도에서도 차이 tenser가 더 좋음
webpack 4: access the mode flag from webpack.config.js file · Issue #6460 · webpack/webpack
Do you want to request a feature or report a bug? feature If this is a feature request, what is motivation or use case for changing the behavior? Since webpack 4 introduces an official --mode it'd be nice to be able to access it, otherwi...
https://github.com/webpack/webpack/issues/6460
Webpack & Uglify로 console.logs 제거
UglifyJsPlugin을 사용하면 주석, 경고, 콘솔 로그 를 처리 할 수 있지만 개발 모드에서 이들을 모두 제거하는 것은 좋지 않습니다. 먼저 prov env or dev env에 대해 webpack을 (를) 실행 중인지 확인하십시오. prod env 인 경우 다음과 같이 이러한 항목을 모두 제거 할 수 있습니다. var debug = process.env.NODE_ENV !== "production"; plugins: !debug ?
https://www.it-swarm.dev/ko/reactjs/webpack-amp-uglify%EB%A1%9C-consolelogs-%EC%A0%9C%EA%B1%B0/828827810/
