|
| 1 | +### Preact Website Update |
| 2 | + |
| 3 | +**Size before:** _(via [size-plugin](https://github.com/googlechromelabs/size-plugin)) |
| 4 | + |
| 5 | +WPT: https://www.webpagetest.org/result/181210_P8_82a008b7a17bc1c55c61197672205e93/ |
| 6 | +LH: https://www.webpagetest.org/lighthouse.php?test=181210_P8_82a008b7a17bc1c55c61197672205e93&run=3 |
| 7 | + |
| 8 | +``` |
| 9 | + a3d80eb575b803a6508e.worker.js ⏤ 216 kB |
| 10 | + bundle.js ⏤ 33.6 kB |
| 11 | + 1.80d97f20c0fd15d2e7c6.chunk.js ⏤ 3.21 kB |
| 12 | + 2.f0ec73293bbbd9656786.chunk.js ⏤ 8.77 kB |
| 13 | + repl.96b61a2ae529b974054a.chunk.js ⏤ 70.1 kB |
| 14 | + style.css ⏤ 6.66 kB |
| 15 | + index.html ⏤ 2.23 kB |
| 16 | + sw.js ⏤ 10 kB (+2 B) |
| 17 | + appcache/manifest.html ⏤ 66 B |
| 18 | +``` |
| 19 | + |
| 20 | +**Size After:** |
| 21 | + |
| 22 | +``` |
| 23 | + 247ee39acd39bae81efc.worker.js ⏤ 217 kB |
| 24 | + bundle.js ⏤ 33.8 kB |
| 25 | + 1.********************.chunk.js ⏤ 3.21 kB |
| 26 | + 2.********************.chunk.js ⏤ 8.77 kB |
| 27 | + repl.********************.chunk.js ⏤ 71.9 kB (+1.71 kB) |
| 28 | + style.css ⏤ 6.66 kB |
| 29 | + index.html ⏤ 2.23 kB |
| 30 | + sw.js ⏤ 10 kB (-8 B) |
| 31 | + appcache/manifest.html ⏤ 66 B |
| 32 | +``` |
| 33 | + |
| 34 | +### RCA |
| 35 | + |
| 36 | +- bundle.js increased by 1.5kB because of marked: (+2kB to 7.2kB: https://bundlephobia.com/result?p=marked@0.5.2) |
| 37 | +- highlight.js increased in size dramatically over the past few releases, though we're subsetting |
| 38 | +- polyfills increased in size. switch from fetch to unfetch helped, code-splitting removed the issue entirely |
| 39 | +- classnames increased in size a bit. it also isn't getting bundled optimally due to a nonstandard UMD wrapper |
| 40 | +- FCP was always a bit bad since only the app shell is prerendered |
| 41 | + |
| 42 | +**After webpack + dep updates:** |
| 43 | + |
| 44 | +``` |
| 45 | + ae1ee828a2ca1fab34e4.worker.js ⏤ 214 kB |
| 46 | + editor.44a85.css ⏤ 2.14 kB |
| 47 | + editor.452bc.chunk.js ⏤ 69 kB |
| 48 | + emoji.d52cc.chunk.js ⏤ 8.75 kB |
| 49 | + main.3b5f6.css ⏤ 6.6 kB |
| 50 | + main.js ⏤ 29.9 kB |
| 51 | + offline.e400f.chunk.js ⏤ 801 B |
| 52 | + polyfills.js ⏤ 2.01 kB |
| 53 | + repl.45b46.css ⏤ 899 B |
| 54 | + repl.34587.chunk.js ⏤ 2.28 kB |
| 55 | + index.html ⏤ 2.22 kB |
| 56 | + sw.js ⏤ 10.4 kB (+2 B) |
| 57 | + appcache/manifest.html ⏤ 86 B |
| 58 | +``` |
| 59 | + |
| 60 | +| Metric | Start | Final | |
| 61 | +|-------------|--------|--------| |
| 62 | +| FCP | 1300ms | 1300ms | |
| 63 | +| TTI | 5900ms | 2950ms | |
| 64 | +| Speed Index | 2380ms | 1910ms | |
0 commit comments