News for hackers. Stuff that matters.
Re:Half a second delay caused a 20% drop in traffic by narag on Wednesday February 04, 2009 @12:47PM (#466106)
If I understood prakash's comment, the first way is actually making it faster, either by generating it faster or by caching. I usually launch four or fives sites at once. HN is the first to load, so I usually start browsing it instead of the (slower) others.

Known tricks are explicit sizes for tables and images. The HTML file itself is loaded fast so you can start reading while images are loading.

There's also the opposite method: preloading images so, once the needed items are in the browser, the page renders faster.

I wonder how it would work to preload the images for the initially visible part of a page and leave for later the ones that you must scroll to see.

I've read recently about using sprites for the graphics: one big image with a mosaic of little images used, then split using CSS. This trick reduces the number of HTTP requests.

Re:Half a second delay caused a 20% drop in traffic by nfriedly on Wednesday February 04, 2009 @10:35PM (#467050)
> I wonder how it would work to preload the images for the initially visible part of a page and leave for later the ones that you must scroll to see.

Yahoo has an open source js library that does exactly that: http://developer.yahoo.com/yui/imageloader/