- Notifications
You must be signed in to change notification settings - Fork20.6k
Commit27303c6
authored
Build: Switch the minifier from UglifyJS to Terser
UglifyJS is ES5-only, while Terser supports newer ECMAScript versions. jQueryis authored in ES5 but jQuery 4.x will also have an ESM build that cannot beminified using UglifyJS directly.We could strip the `export` statement, minify via UglifyJS and re-add one butthat increases complexity & may not fully play nice with source maps.On the other hand, switching to Terser increases the minfied size by just 324bytes and the minified gzipped one by just 70 bytes. Such differences largelydisappear among bigger size gains from the `3.x-stable` line - around 2.7 KBminified gzipped as of now.Closesgh-52581 parent988a568 commit27303c6
4 files changed
+19
-18
lines changedLines changed: 14 additions & 13 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
333 | 333 |
| |
334 | 334 |
| |
335 | 335 |
| |
336 |
| - | |
| 336 | + | |
337 | 337 |
| |
338 | 338 |
| |
339 | 339 |
| |
340 | 340 |
| |
341 | 341 |
| |
342 | 342 |
| |
343 |
| - | |
344 |
| - | |
345 |
| - | |
346 |
| - | |
347 |
| - | |
348 |
| - | |
349 |
| - | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
350 | 353 |
| |
351 |
| - | |
352 |
| - | |
353 | 354 |
| |
354 |
| - | |
| 355 | + | |
355 | 356 |
| |
356 | 357 |
| |
357 | 358 |
| |
| |||
420 | 421 |
| |
421 | 422 |
| |
422 | 423 |
| |
423 |
| - | |
| 424 | + | |
424 | 425 |
| |
425 | 426 |
| |
426 | 427 |
| |
| |||
431 | 432 |
| |
432 | 433 |
| |
433 | 434 |
| |
434 |
| - | |
| 435 | + | |
435 | 436 |
| |
436 | 437 |
| |
437 | 438 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
339 | 339 |
| |
340 | 340 |
| |
341 | 341 |
| |
342 |
| - | |
| 342 | + | |
343 | 343 |
| |
344 | 344 |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3 | 3 |
| |
4 | 4 |
| |
5 | 5 |
| |
6 |
| - | |
| 6 | + | |
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
|
Lines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
35 | 35 |
| |
36 | 36 |
| |
37 | 37 |
| |
38 |
| - | |
39 | 38 |
| |
40 | 39 |
| |
41 | 40 |
| |
42 | 41 |
| |
43 | 42 |
| |
44 | 43 |
| |
45 | 44 |
| |
| 45 | + | |
46 | 46 |
| |
47 | 47 |
| |
48 | 48 |
| |
| |||
67 | 67 |
| |
68 | 68 |
| |
69 | 69 |
| |
70 |
| - | |
71 |
| - | |
| 70 | + | |
| 71 | + | |
72 | 72 |
| |
73 | 73 |
| |
74 | 74 |
| |
|
0 commit comments
Comments
(0)