Skip to content

Instantly share code, notes, and snippets.

@vigzmv
Created February 15, 2019 05:50
Show Gist options
  • Save vigzmv/9fb9ae600031805b91303649a96680bd to your computer and use it in GitHub Desktop.
Save vigzmv/9fb9ae600031805b91303649a96680bd to your computer and use it in GitHub Desktop.
Client Performance Logging
const {
domLoading,
domComplete,
domInteractive,
domContentLoadedEventStart
} = window.performance.timing;
const tti = domInteractive - domLoading;
const dcl = domContentLoadedEventStart - domLoading;
const complete = domComplete - domLoading;
console.info({ perf: {tti, dcl, complete} });
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment