Whenever the base URL is redirected (for instance, www.google.com being redirected to https://www.google.com/?gws_rd=ssl), some of the top-level data like _loadEventStart, _loadEventEnd, _domContentLoadedEventStart, _domContentLoadedEventEnd are all set to 0.
Is there a reason why it is the way it is and is there a work-around to get at the real values for the above metrics?
I’ll have to take a look but those numbers are just pulled from window.performance and there may be a restriction or something else going on becuase of the redirect to a SSL page.
Pat, thanks. I think it was my oversight. Turns out, I saw these numbers as 0 on IE-8/9 which doesn’t support nav-timing API altogether. On chrome and IE-10+, I do see these values being populated correctly even for redirected base pages.
Is there a work around to get these metrics for browsers that doesn’t support nav-timing API in another fashion from WPT?
For instance, _loadEventStart is very close to page.pageTimings.onLoad (or _loadTime).
While for loadEventEnd, there are other alternatives like you mentioned – _loadTime and _docTime, are there any work arounds for determining when the domContentLoaded event was fired? On browsers supporting nav-timing API, this is straightforward. But, for older browsers, like IE9 (or even safari), are there metrics in the HAR file that are close enough to the domContentLoadedEventStart?
I noticed that WPT itself skips showing the “DOM Content Loaded” strip if it is IE9 or below, but is there a close enough value that can be used in such cases?