5 ms·
It's all fun and games until we realize our web designers put a four megabyte jpeg on the index page.
by thresh 8y ago
It's all fun and games until we realize our web designers put a four megabyte jpeg on the index page.
- Sami_Lehtinen 8y agoWhat, JPEG? I thought real designers prefer high quality content and use 20 megabyte PNGs. (been there, done that)
- udp 8y agoThe 4 MB JPEG would be downloaded, though, while the headers would be uploaded. Consumer internet has terrible upload speeds in general.
- dcbadacd 8y agoGiven today's screen resolution, anything less would probably look horrible.
- seanwilson 8y agoUse SVG. Infinite detail. Doesn't work for photos though.
- benhoyt 8y agoI think this is a really good point. While I like the article's focus on depth, and thinking about the small stuff is important, saving a few bytes on headers is going to be blown out of the water by all the images, JS, CSS, and 3rd-party pixels being loaded. "Profile before optimizing" applies here too.
- mcguire 8y ago1. Images are transferred once, not with every request. 2. Most requests and many responses are all or mostly headers. 3. Intermediaries. 4. Header compression is at the protocol level; if it's done wrong, the best js/css/whatever policy can't do anything to improve it.
- youngtaff 8y agoBut I bet you most people will never profile this. We have a tendency to focus on page size but what really matters is the user experience. For all the advice of putting making sure the first 15KB of a page counts, inlining critical styles etc., it that response has 4KB of headers e.g. large cookies, then all of a sudden you've got 11KB!