@zendesk/retrace
Version:
define and capture Product Operation Traces along with computed metrics with an optional friendly React beacon API
15 lines (13 loc) • 406 B
text/typescript
import type { Span } from '../spanTypes'
import { TraceManager } from '../TraceManager'
import type { RelationSchemasBase } from '../types'
export function processSpans<
const RelationSchemasT extends RelationSchemasBase<RelationSchemasT>,
>(
spans: Span<RelationSchemasT>[],
traceManager: TraceManager<RelationSchemasT>,
) {
spans.forEach((span, i) => {
traceManager.processSpan(span)
})
}