@grafana/faro-web-sdk
Version:
Faro instrumentations, metas, transports for web.
15 lines • 626 B
JavaScript
import { BaseInstrumentation, VERSION } from '@grafana/faro-core';
import { WebVitalsWithAttribution } from './webVitalsWithAttribution';
export class WebVitalsInstrumentation extends BaseInstrumentation {
constructor() {
super(...arguments);
this.name = '@grafana/faro-web-sdk:instrumentation-web-vitals';
this.version = VERSION;
}
initialize() {
this.logDebug('Initializing');
const webVitals = new WebVitalsWithAttribution(this.api.pushMeasurement, this.config.webVitalsInstrumentation);
webVitals.initialize();
}
}
//# sourceMappingURL=instrumentation.js.map