-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
The Hilla demo uses this function to initialize the frontend observability insturmentation:
| export default function initTelemetry(): void { | |
| const provider = new WebTracerProvider(); | |
| provider.register({ | |
| contextManager: new ZoneContextManager(), | |
| }); | |
| provider.addSpanProcessor( | |
| new SimpleSpanProcessor( | |
| new HillaEndpointExporter({ | |
| // eslint-disable-next-line @typescript-eslint/no-misused-promises | |
| endpoint: ObservabilityEndpoint.export, | |
| }), | |
| ), | |
| ); | |
| registerInstrumentations({ | |
| instrumentations: [new DocumentLoadInstrumentation()], | |
| }); | |
| } |
We should provide this functionality embedded in the kit to facilitate the initialization of frontend observability.
Metadata
Metadata
Assignees
Labels
No labels