-
-
Notifications
You must be signed in to change notification settings - Fork 157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
doc: webpack v4 needs terser v4 #378
Conversation
Codecov Report
@@ Coverage Diff @@
## master #378 +/- ##
=======================================
Coverage 96.98% 96.98%
=======================================
Files 3 3
Lines 299 299
Branches 128 128
=======================================
Hits 290 290
Misses 8 8
Partials 1 1 Continue to review full report at Codecov.
|
@@ -20,10 +20,10 @@ This plugin uses [terser](https://github.com/terser-js/terser) to minify your Ja | |||
|
|||
If you are using webpack v5 or above you do not need to install this plugin. Webpack v5 comes with the latest `terser-webpack-plugin` out of the box. | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please describe it here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your answer. Do you mean I have to (1) additionally describe it here OR (2) remove what I suggested and add it there only?
Suggestion:
If you are using webpack v5 or above you do not need to install this plugin. Webpack v5 comes with the latest
terser-webpack-plugin
out of the box. Using Webpack v4, you have to installterser-webpack-plugin
v4.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to change original setup, let's describe separately about webpack@4, anyway I strongly recommend to migrate on v5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alexander-akait I just removed my original suggestion and tried to follow your advice. Let me know if it's OK!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All is OK 👍
Can you accept CLA? |
Done! |
Sometimes bot is buggy, don't worry |
Thanks |
This PR contains a:
Motivation / Use-Case
Many peoples seems upset because they failed to install this lib with webpack 4: #335 (comment). Since "Webpack v5 comes with the latest terser-webpack-plugin out of the box", the only users that want to install it manually would be the one that use v4. I guess people would be more happy with this hint.
Scenario: I did not know terser and had to improve a webpack (v4) config file. I read that I have to replace uglify plugin which is not maintained with terser. So I went to this repo and copy/pasted the install line as stated in the readme. It failed.
Feel free to ask me anything, I would be super happy to improve my PR!