Files
Kilo-Org_kilocode/packages/kilo-docs/instrumentation-client.ts
T

12 lines
355 B
TypeScript

import posthog from "posthog-js"
if (process.env.NEXT_PUBLIC_POSTHOG_KEY) {
posthog.init(process.env.NEXT_PUBLIC_POSTHOG_KEY, {
api_host: "/ingest",
ui_host: "https://us.posthog.com",
person_profiles: "identified_only",
capture_pageview: false, // Handled manually in _app.tsx on routeChangeComplete
capture_pageleave: true,
})
}