refactor(posthog): unify project key for all AIRI surfaces and streamline configuration
This commit is contained in:
@@ -1,9 +1,12 @@
|
||||
import posthog from 'posthog-js'
|
||||
|
||||
import { DEFAULT_POSTHOG_CONFIG, POSTHOG_PROJECT_KEY_DOCS } from '../../../posthog.config'
|
||||
import { DEFAULT_POSTHOG_CONFIG, POSTHOG_PROJECT_KEY } from '../../../posthog.config'
|
||||
|
||||
if (!import.meta.env.DEV) {
|
||||
posthog.init(POSTHOG_PROJECT_KEY_DOCS, {
|
||||
posthog.init(POSTHOG_PROJECT_KEY, {
|
||||
...DEFAULT_POSTHOG_CONFIG,
|
||||
})
|
||||
// Tag docs-site traffic so it can be told apart from the app surfaces
|
||||
// inside the shared project.
|
||||
posthog.register({ surface: 'docs' })
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user