diff options
author | Michał Gołębiowski-Owczarek <m.goleb@gmail.com> | 2023-05-31 18:59:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-31 18:59:35 +0200 |
commit | 27303c6be09b8fc24c13454deae234e480cbf995 (patch) | |
tree | 16479591d00d12db7f3e4341c10a35111835ecef /src | |
parent | 988a56847de301ce18a653f84b07c5af432a269f (diff) | |
download | jquery-27303c6be09b8fc24c13454deae234e480cbf995.tar.gz jquery-27303c6be09b8fc24c13454deae234e480cbf995.zip |
Build: Switch the minifier from UglifyJS to Terser
UglifyJS is ES5-only, while Terser supports newer ECMAScript versions. jQuery
is authored in ES5 but jQuery 4.x will also have an ESM build that cannot be
minified using UglifyJS directly.
We could strip the `export` statement, minify via UglifyJS and re-add one but
that increases complexity & may not fully play nice with source maps.
On the other hand, switching to Terser increases the minfied size by just 324
bytes and the minified gzipped one by just 70 bytes. Such differences largely
disappear among bigger size gains from the `3.x-stable` line - around 2.7 KB
minified gzipped as of now.
Closes gh-5258
Diffstat (limited to 'src')
0 files changed, 0 insertions, 0 deletions