Skip to content

Instantly share code, notes, and snippets.

@andreasvirkus
Created June 16, 2017 16:17
Show Gist options
  • Save andreasvirkus/bd967c2ed9f6a65c1889ad4510afd3b7 to your computer and use it in GitHub Desktop.
Save andreasvirkus/bd967c2ed9f6a65c1889ad4510afd3b7 to your computer and use it in GitHub Desktop.
module.exports = function() {
let now = new Date().getTime();
let loadTime = now - performance.timing.navigationStart;
console.log("User-perceived page loading time: " + loadTime);
return loadTime;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment