monitor-api - v1.3.0
    Preparing search index...

    Interface IEventCollector

    Public API exposed by the event collector.

    interface IEventCollector {
        onEvent: SSignal<MonitorEvent | null>;
        snapshot: SSignal<EventSnapshot>;
        clearLog(): void;
        destroy(): void;
        emit(label: string, data?: Record<string, unknown>): void;
        start(): void;
        stop(): void;
    }
    Index

    Properties

    onEvent: SSignal<MonitorEvent | null>

    Signal set to the latest recorded event, or null before any event is recorded.

    snapshot: SSignal<EventSnapshot>

    Signal containing retained events and derived label counts.

    Methods

    • Records an application event directly without dispatching a browser CustomEvent.

      Parameters

      • label: string
      • Optionaldata: Record<string, unknown>

      Returns void

    • Starts listening for events emitted by emitMonitorEvent.

      Returns void