Settings

Theme

Google.com source code (not simple anymore)

15 points by rk1987 11 years ago · 12 comments · 1 min read


view-source:https://www.google.com/

Maybe it's just me, but realized google.com source code (HTML) used to be very simple but it looks very different now.

Try navigating HTML elements using dev tools.

carrja99 11 years ago

And here I thought this was a post about the google.com source code being leaked. :-)

I'd imagine that the rendered HTML is probably produced by a legacy system that stitches together a lot of different templates, some maybe even unintentionally.

bstackd 11 years ago

No surprise, they have to compress like mad and avoid superfluous http requests. That sort of optimisation will never look fancy

5h 11 years ago

I wonder why there are multiple style elements, in div#footcnt there are 2 right next to each other, they could have saved a whole "</style><style>" there, think of the bandwidth!

/s

mdturnerphys 11 years ago

Quantified: https://news.ycombinator.com/item?id=4647834

egonschiele 11 years ago

I wonder if the giant script was an external file, and now it's being splat on the page?

  • connerbryan 11 years ago

    I'd believe it. As someone else mentioned above, they've also started inlining image data, so I wouldn't be surprised if these changes all fell under the goal of minimizing HTTP requests.

gotothrowaway 11 years ago

The other day I noticed that they're inlining image data in the src attribute instead of pointing at an external URL. Really taking things to the next level all-around - I wonder when that will become the norm instead of css image sprites.

  • nonuby 11 years ago

    Hopefully never, and certainly not with http 2.0 around the corner (this adoption wont be so slow, things are already starting to fall neatly into place). It's a micro-optimization Google can afford to do, others will just rely on optimize images size and a CDN instead (possibly an extra hostname) and vast majority wont/don't even bother..

philippnagel 11 years ago

Click-bait ;)

karangoeluw 11 years ago

I don't get it, what's the point of this post? How is it adding any new knowledge to the readers?

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection