Navigation Timing API 测量辅助工具
Timing.js is a small set of helpers for working with the Navigation Timing API to identify where your application is spending its time. Useful as a standalone script, DevTools Snippet or bookmarklet.
firstPaint across Chrome, Opera and IE11 to timing.getTimes().firstPaint. Firefox may be able to do similar with MozAfterPaintfirstPaintTime (firstPaint - load/nav start)domReadyTime, initDomTreeTime, loadEventTime, loadTime, redirectTime, requestTime, unloadEventTime connectTimeDownload the latest version or just git clone https://github.com/addyosmani/timing.js.git.
$ bower install timing-js
$ npm install timing.js
By default, running the script will print out a summary table of measurements. The API for the script is as follows:
Get measurements:
timing.getTimes();
Print a summary table of measurements (uses console.table()):
timing.printSimpleTable();
Also works in Firefox DevTools (Firefox Nightly only for now):
Print a complete table of measurements (including rest of window.performance):
timing.printTable();
timing.getTimes()Chrome:
…
Firefox:
IE 11:
Run npm install to install necessary dependencies for building the library. Check that npm run jshint doesn't throw any exceptions and then run npm run minify to minify.
Released under an MIT license.
暂无开放 Issues,或尚未同步最近议题。