ガイド
Firebase Performanceのチュートリアル
capgoのcapacitor-firebase-performanceを使用
CapacitorのFirebase Performanceモニタリング用プラグイン
インストール
bun add @capgo/capacitor-firebase-performance
bunx cap sync
このプラグインが公開するもの
startTrace- トレースを開始stopTrace- トレースを停止incrementMetric- 指定されたトレースで選択されたメトリックの名前で、指定された値で原子的にインクリメントincrementBy値setEnabled- アプリの起動時にパフォーマンスモニタリングを有効または無効にする。
Example Usage
startTrace
トレースを開始します。
import { FirebasePerformance } from '@capgo/capacitor-firebase-performance';
await FirebasePerformance.startTrace({} as StartTraceOptions);
stopTrace
トレースを停止します。
import { FirebasePerformance } from '@capgo/capacitor-firebase-performance';
await FirebasePerformance.stopTrace({} as StopTraceOptions);
incrementMetric
指定されたトレースで選択されたメトリックの名前で、値を使用して原子的にインクリメントします。 incrementBy アプリの起動時にパフォーマンスモニタリングを有効または無効にする。
import { FirebasePerformance } from '@capgo/capacitor-firebase-performance';
await FirebasePerformance.incrementMetric({} as IncrementMetricOptions);
setEnabled
Full Reference
import { FirebasePerformance } from '@capgo/capacitor-firebase-performance';
await FirebasePerformance.setEnabled({} as SetEnabledOptions);
__CAPGO_KEEP_0__:
- https://GitHub.com/Cap-go/__CAPGO_KEEP_1__-firebase/tree/main/packages/performance https://github.com/Cap-go/capacitor-firebase/tree/main/packages/performance
- フッター