import TelemetryReporter from "vscode-extension-telemetry" ; const pkgJson = require ( "../../../package.json" ) ; const extensionId = pkgJson . name ; const extensionVersion = pkgJson . version ; const key = "864f39be-f021-4e3b-98fb-18690e2e7066" ; export class Telemetry { public static reporter : TelemetryReporter ; public static initialize ( ) { Telemetry . reporter = new TelemetryReporter ( extensionId , extensionVersion , key ) ; } public static sendEvent = ( eventName , properties ? , measurements ? ) => { try { Telemetry . reporter . sendTelemetryEvent ( eventName , properties , measurements ) ; } catch { } } ; public static deactivate ( ) { Telemetry . reporter . dispose ( ) ; } } Telemetry . initialize ( ) ;