@aller/blink-labrador
Advanced tools
Comparing version 8.24.12-alpha.0 to 8.24.14-alpha.0
@@ -210,6 +210,7 @@ "use strict"; | ||
var webVitals = vitalsTracker.getAllMetrics(); | ||
var now = vitalsTracker.now(); | ||
var now = performance.now() || 0; | ||
window.setTimeout(function () { | ||
if (webVitals) { | ||
webVitals.visitDurationAtSend = now; | ||
console.log(webVitals); | ||
_this_1.blink.webVitals({ webVitals: webVitals }); | ||
@@ -223,3 +224,4 @@ // start another measurement for sending with the hidden state | ||
if (webVitals) { | ||
webVitals.visitDurationAtSend = now; | ||
webVitals.visitDurationAtSend = performance.now() || 0; | ||
console.log(webVitals); | ||
_this_1.blink.webVitals({ webVitals: webVitals }); | ||
@@ -226,0 +228,0 @@ } |
@@ -17,3 +17,3 @@ import type { Metric } from 'web-vitals'; | ||
webVitalsReport: WebVitalsReport; | ||
mapMetric(metric: Metric): LogMetric | undefined; | ||
mapMetric(metric: Metric): void; | ||
cls(): void; | ||
@@ -20,0 +20,0 @@ ttfb(): void; |
@@ -16,3 +16,3 @@ "use strict"; | ||
FID: null, | ||
visitDurationAtSend: 0, | ||
visitDurationAtSend: performance.now() || 0, | ||
}; | ||
@@ -22,5 +22,6 @@ } | ||
var report = this.webVitalsReport[metric.name]; | ||
console.log(metric.name); | ||
if (typeof report === 'undefined') | ||
return; | ||
return formatCWVreport(metric); | ||
this.webVitalsReport[metric.name] = formatCWVreport(metric); | ||
}; | ||
@@ -84,3 +85,3 @@ ChromeWebVitals.prototype.cls = function () { | ||
this.fid(); | ||
this.webVitalsReport.visitDurationAtSend = now || 0; | ||
// this.webVitalsReport.visitDurationAtSend = now || 0; | ||
return this.webVitalsReport; | ||
@@ -87,0 +88,0 @@ }; |
{ | ||
"name": "@aller/blink-labrador", | ||
"version": "8.24.12-alpha.0", | ||
"version": "8.24.14-alpha.0", | ||
"description": "Library for using blink on Labrador", | ||
@@ -76,3 +76,3 @@ "main": "lib/main.js", | ||
"dependencies": { | ||
"@aller/blink": "^8.24.12-alpha.0", | ||
"@aller/blink": "^8.24.14-alpha.0", | ||
"@soldotno/aller-in-view": "^3.0.2", | ||
@@ -96,3 +96,3 @@ "react": "^16.11.0", | ||
}, | ||
"gitHead": "201c8dfe20727f9adb32792e96e118be34f4c421" | ||
"gitHead": "d5f7e2f1432a4d713ea8eac2ff5d20369ca25528" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
469473
6331