lecture 19 question

4 views
Skip to first unread message

Maria Jabon

unread,
Dec 8, 2008, 2:44:10 AM12/8/08
to CS193H High Performance Web Sites
One question in lecture 19 is Why is this measurement done at the
onload event?

Any ideas?

Tony Wu

unread,
Dec 8, 2008, 2:46:15 AM12/8/08
to cs193...@googlegroups.com
I think because the time the onload event fires is the time that the browser stops showing the page as "loading," so that's the time when the user is told that the page is done.

-Tony

Maria Jabon

unread,
Dec 8, 2008, 2:46:57 AM12/8/08
to cs193...@googlegroups.com
Thanks.

Vibhor Nanavati

unread,
Dec 8, 2008, 3:52:56 AM12/8/08
to cs193...@googlegroups.com
Also I remember Steve mentioning that many sites use onload event to trigger handlers that can focus the cursor on the form input (e.g search box or username field). The earlier those handlers get triggered the better.
--
VIBHOR NANAVATI <vib...@stanford.edu>

Steve Souders

unread,
Dec 8, 2008, 1:43:57 PM12/8/08
to cs193...@googlegroups.com
This was mentioned in lecture #18 ( http://cs193h.stevesouders.com/slides/cs193h-18-split-the-initial-payload.ppt ). The handout for that lecture ("Split the Initial Payload") says:
YSlowPlus stops its analysis at the onload event because functionality needed after this point can, and should, be downloaded after the initial page has rendered.
("YSlowPlus" is a (hoped for) version of YSlow that includes these new performance best practices.)

-Steve
Reply all
Reply to author
Forward
0 new messages