BOOMR.plugins. NavigationTiming


The Navigation Timing plugin collects performance metrics collected by modern user agents that support the W3C NavigationTiming specification.

This plugin also adds similar ResourceTiming metrics for any XHR beacons.

For information on how to include this plugin, see the Building tutorial.

Beacon Parameters

All beacon parameters are prefixed with nt_.

This plugin adds the following parameters to the beacon for Page Loads:

  • nt_red_cnt: performance.navigation.redirectCount
  • nt_nav_type: performance.navigation.type
  • nt_nav_st: performance.timing.navigationStart
  • nt_red_st: performance.timing.redirectStart
  • nt_red_end: performance.timing.redirectEnd
  • nt_fet_st: performance.timing.fetchStart
  • nt_dns_st: performance.timing.domainLookupStart
  • nt_dns_end: performance.timing.domainLookupEnd
  • nt_con_st: performance.timing.connectStart
  • nt_con_end: performance.timing.connectEnd
  • nt_req_st: performance.timing.requestStart
  • nt_res_st: performance.timing.responseStart
  • nt_res_end: performance.timing.responseEnd
  • nt_domloading: performance.timing.domLoading
  • nt_domint: performance.timing.domInteractive
  • nt_domcontloaded_st: performance.timing.domContentLoadedEventStart
  • nt_domcontloaded_end: performance.timing.domContentLoadedEventEnd
  • nt_domcomp: performance.timing.domComplete
  • nt_load_st: performance.timing.loadEventStart
  • nt_load_end: performance.timing.loadEventEnd
  • nt_unload_st: performance.timing.unloadEventStart
  • nt_unload_end: performance.timing.unloadEventEnd
  • nt_ssl_st: performance.timing.secureConnectionStart
  • nt_spdy: 1 if page was loaded over SPDY, 0 otherwise. Only available in Chrome when it doesn't support NavigationTiming2. If NavigationTiming2 is supported, nt_protocol will be added instead.
  • nt_first_paint: The time when the first paint happened. If the browser supports the Paint Timing API, this is the first-paint time in milliseconds since the epoch. Else, on Internet Explorer, this is the msFirstPaint value, in milliseconds since the epoch. On Chrome, this is using loadTimes().firstPaintTime and is converted from seconds.microseconds into milliseconds since the epoch.
  • nt_cinf: Chrome chrome.loadTimes().connectionInfo. Only available in Chrome when it doesn't support NavigationTiming2. If NavigationTiming2 is supported, nt_protocol will be added instead.
  • nt_protocol: NavigationTiming2's nextHopProtocol
  • nt_bad: If we detected that any NavigationTiming metrics looked odd, such as responseEnd in the far future or fetchStart before navigationStart.
  • nt_worker_start: NavigationTiming2 workerStart
  • nt_enc_size: NavigationTiming2 encodedBodySize
  • nt_dec_size: NavigationTiming2 decodedBodySize
  • nt_trn_size: NavigationTiming2 transferSize

For XHR beacons, the following parameters are added (via ResourceTiming):

  • nt_red_st: redirectStart
  • nt_red_end: redirectEnd
  • nt_fet_st: fetchStart
  • nt_dns_st: domainLookupStart
  • nt_dns_end: domainLookupEnd
  • nt_con_st: connectStart
  • nt_con_end: connectEnd
  • nt_req_st: requestStart
  • nt_res_st: responseStart
  • nt_res_end: responseEnd
  • nt_load_st: loadEventStart
  • nt_load_end: loadEventEnd
  • nt_ssl_st: secureConnectionStart

See:

Methods


init()

Initializes the plugin.

This plugin does not have any configuration.

Returns:

BOOMR.plugins.NavigationTiming The NavigationTiming plugin for chaining


is_complete()

Whether or not this plugin is complete

Returns:

Type: boolean

true if the plugin is complete