DEV Community

Discussion on: I'm Addy Osmani, Ask Me Anything!

Collapse
 
rkoutnik profile image
Randall Koutnik

I'm sure you've encountered some real humdingers when trying to optimize slow pages. Got a favorite story about some ridiculous performance bug you've encountered?

Collapse
 
ben profile image
Ben Halpern

Collapse
 
addyosmani profile image
Addy Osmani

Hmmmm. The worst optimized site I've encountered in my career was probably just a few weeks back :) This was a site with a number of verticals where the front-end teams for each vertical were given the autonomy to decide how they were going to ship their part of the site.

As it turns out, this didn't end well.

Rather than each "vertical" working collaboratively on the stack the site would use, they ended up with vaguely similar, yet different things. From the time you entered the site to the time you checked out, you could easily load 6 different versions of React and Redux. Their JavaScript bundles were multiple MBs in size (a combination of utility library choices and not employing enough much code-splitting or vendor chunking). It was a disaster.

One thing we hope can change this is encouraging more teams to adopt performance budgets and stick closely to them. There's no way the web can compete on mobile if we're going to send down so much code that accomplishes so little.

Oh, other stories.

  • Ran into multiple sites shipping 80MB+ of images to their users for one page...on mobile
  • Ran into a site that was Service Worker caching 8GB of video... accidentally

There are so many ridiculous perf stories out there :)

Thread Thread
 
ben profile image
Ben Halpern

Oh my goodness this is making me squirm.

Thread Thread
 
rhymes profile image
rhymes • Edited

OMG six different versions of the same library is definitely the result of poor communication. I can't wait for an AI powered browser opening alerts saying "please tell those developer fools that did this website to talk to each other :D"

The imaging thing is all very common.

I've seen galleries/grids of images rendered using the original images uploaded by the operator, which obviously were neither checked for size nor resized automatically.

Thread Thread
 
galdin profile image
Galdin Raphael

Those stories sound like they're really easy to repeat though.