Re: Notification for new navigation timing entries

On Mon, Feb 17, 2014 at 9:33 AM, Joshua Peek <> wrote:

> Theres no notification when
> new performance entries have been recorded. This requires invasive
> code to recheck the performance entries buffer.

Josh, why wouldn't you just use measure / clearMarks? I don't think you
need to traverse the full buffer.

function markIt(name) {
  performance.mark(name); // or use measure with optional start/end params
  // grab the timing data, do what you need to do with it

// your code
// more code

Point being, you know when the event is available.. it's when you call
mark. For NavTiming this happens to be after onloadEnd.


Received on Friday, 28 February 2014 18:50:20 UTC