Verwendung von @capgo/capacitor-appinsights
Eine Wrapper-Around die https://github.com/apptopia/appinsights SDK.
Installieren
bun add @capgo/capacitor-appinsights
bunx cap sync
Was dieses Plugin enthält
init- Initialisierung der AppInsights-SDK.setUserId- Setzen oder Aktualisieren der Benutzer-ID nach der Initialisierung.getState- Holen Sie sich den aktuellen Zustand des SDK.
Beispielhafte Verwendung
init
Initialisieren Sie das AppInsights-SDK.
import { CapacitorAppInsights } from '@capgo/capacitor-appinsights';
await CapacitorAppInsights.init({} as {
partnerId: string; // Provided by our business unit
partnerKey: string; // Provided by our business unit
});
setUserId
Setzen oder aktualisieren Sie die Benutzer-ID nach der Initialisierung.
import { CapacitorAppInsights } from '@capgo/capacitor-appinsights';
await CapacitorAppInsights.setUserId({} as { userId: string });
getState
Holen Sie sich den aktuellen Zustand des SDK.
import { CapacitorAppInsights } from '@capgo/capacitor-appinsights';
await CapacitorAppInsights.getState();
Vollständige Referenz
- GitHub: https://github.com/Cap-go/capacitor-appinsights/
- Dokumentation: /docs/plugins/appinsights/
Fortsetzen Sie mit der Verwendung von @capgo/capacitor-appinsights
Wenn Sie @__CAPGO_KEEP_0__/__CAPGO_KEEP_1__-appinsights verwenden Wenn Sie @capgo/capacitor-appinsights verwenden zur Planung von native Plugin-Arbeiten, verbinden Sie es mit @capgo/capacitor-appinsights zur Implementierungs-Detail in @capgo/capacitor-appinsights Anleitung zum Starten zur Implementierungs-Detail in Anleitung zum Starten Capgo Plugin-Verzeichnis zur Produkt-Workflow in Capgo Plugin-Verzeichnis Capacitor Plugins von Capgo zur Implementierungs-Detail in Capacitor Plugins von Capgo, und Plugins hinzufügen oder aktualisieren zur Implementierungs-Detail in Plugins hinzufügen oder aktualisieren.