MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / withDefaultProperties

Function withDefaultProperties

common/src/analytics.ts:36–46  ·  view source on GitHub ↗
(
  trackEventFn: TrackEventFn,
  defaultProperties: Record<string, unknown>,
)

Source from the content-addressed store, hash-verified

34}
35
36export function withDefaultProperties(
37 trackEventFn: TrackEventFn,
38 defaultProperties: Record<string, unknown>,
39): TrackEventFn {
40 return (params) => {
41 trackEventFn({
42 ...params,
43 properties: { ...defaultProperties, ...params.properties },
44 })
45 }
46}
47
48export function trackEvent({
49 event,

Callers 1

postChatCompletionsFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected