5 ms·
By gzipped size I’m referring to the polyfill bundle itself update: thanks for disambiguating the title, OP!
by wongmjane 6y ago
By gzipped size I’m referring to the polyfill bundle itself
update: thanks for disambiguating the title, OP!
- Ajedi32 6y agoI think that was actually pretty clear from your tweet; it's just the title of this post which is misleading. Edit: For context, previous title was "Twitter web app gzip size dropped from 16.6 KB to 2.7 KB by removing polyfills"
- tosh 6y agoupdated title to clarify, ty!
- vijaybritto 6y agoDo you have any information on how they achieved this?
- wongmjane 6y agoThey now have two production build variations (I’m guessing two Webpack config): modern: ES6+, less polyfill legacy: ES5, more polyfill The appropriate variation is served by detecting browser’s version from the User-Agent string
- axlee 6y agoNote: since v8.0, Angular comes with built-in differential loading and will do all the heavy lifting to achieve exactly that. https://angular.io/guide/deployment#differential-loading https://angular.io/guide/deployment#differential-loading
- wongmjane 6y agoupdate: a Twitter engineer explained how they implemented it in greater detail https://twitter.com/charliecroom/status/1291478104016289799 https://twitter.com/charliecroom/status/1291478104016289799
- ericlewis 6y agoJane!