nanotiming
Advanced tools
Comparing version 5.1.0 to 5.2.0
var assert = require('assert') | ||
var perf = window.performance | ||
var hasPerf = typeof window !== 'undefined' && perf && perf.mark | ||
var perf = typeof window !== 'undefined' && window.performance | ||
var hasPerf = perf && perf.mark | ||
@@ -28,3 +28,3 @@ module.exports = nanotiming | ||
var measure = perf.getEntriesByName(measureName)[0] | ||
cb(measure) | ||
cb(measure, name) | ||
} | ||
@@ -31,0 +31,0 @@ }) |
@@ -5,3 +5,3 @@ { | ||
"repository": "yoshuawuyts/nanotiming", | ||
"version": "5.1.0", | ||
"version": "5.2.0", | ||
"scripts": { | ||
@@ -8,0 +8,0 @@ "deps": "dependency-check . && dependency-check . --extra --no-dev", |
@@ -40,3 +40,3 @@ # nanotiming [![stability][0]][1] | ||
### `endTiming([cb(timing)])` | ||
### `endTiming([cb(timing, name)])` | ||
Close the timing. Measuring the timing is done inside a `requestIdleCallback()` | ||
@@ -43,0 +43,0 @@ tick, so it might not be available immediately. If a callback is passed it will |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5090