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.redirectCountnt_nav_type:performance.navigation.typent_nav_st:performance.timing.navigationStartnt_red_st:performance.timing.redirectStartnt_red_end:performance.timing.redirectEndnt_fet_st:performance.timing.fetchStartnt_dns_st:performance.timing.domainLookupStartnt_dns_end:performance.timing.domainLookupEndnt_con_st:performance.timing.connectStartnt_con_end:performance.timing.connectEndnt_req_st:performance.timing.requestStartnt_res_st:performance.timing.responseStartnt_res_end:performance.timing.responseEndnt_domloading:performance.timing.domLoadingnt_domint:performance.timing.domInteractivent_domcontloaded_st:performance.timing.domContentLoadedEventStartnt_domcontloaded_end:performance.timing.domContentLoadedEventEndnt_domcomp:performance.timing.domCompletent_load_st:performance.timing.loadEventStartnt_load_end:performance.timing.loadEventEndnt_unload_st:performance.timing.unloadEventStartnt_unload_end:performance.timing.unloadEventEndnt_ssl_st:performance.timing.secureConnectionStartnt_spdy:1if page was loaded over SPDY,0otherwise. Only available in Chrome when it doesn't support NavigationTiming2. If NavigationTiming2 is supported,nt_protocolwill be added instead.nt_first_paint: The time when the first paint happened. If the browser supports the Paint Timing API, this is thefirst-painttime in milliseconds since the epoch. Else, on Internet Explorer, this is themsFirstPaintvalue, in milliseconds since the epoch. On Chrome, this is usingloadTimes().firstPaintTimeand is converted from seconds.microseconds into milliseconds since the epoch.nt_cinf: Chromechrome.loadTimes().connectionInfo. Only available in Chrome when it doesn't support NavigationTiming2. If NavigationTiming2 is supported,nt_protocolwill be added instead.nt_protocol: NavigationTiming2'snextHopProtocolnt_bad: If we detected that any NavigationTiming metrics looked odd, such asresponseEndin the far future orfetchStartbeforenavigationStart.nt_worker_start: NavigationTiming2workerStartnt_enc_size: NavigationTiming2encodedBodySizent_dec_size: NavigationTiming2decodedBodySizent_trn_size: NavigationTiming2transferSize
For XHR beacons, the following parameters are added (via ResourceTiming):
nt_red_st:redirectStartnt_red_end:redirectEndnt_fet_st:fetchStartnt_dns_st:domainLookupStartnt_dns_end:domainLookupEndnt_con_st:connectStartnt_con_end:connectEndnt_req_st:requestStartnt_res_st:responseStartnt_res_end:responseEndnt_load_st:loadEventStartnt_load_end:loadEventEndnt_ssl_st:secureConnectionStart
Methods
-
init()
-
Initializes the plugin.
This plugin does not have any configuration.
Returns:
BOOMR.plugins.NavigationTimingThe NavigationTiming plugin for chaining -
is_complete()
-
Whether or not this plugin is complete
Returns:
Type: boolean
trueif the plugin is complete