mirror of
https://github.com/multica-ai/multica.git
synced 2026-07-27 13:06:20 +02:00
Replace mixpanel-browser with posthog-js for frontend analytics. PostHog provides CLI + SQL query support (HogQL) which enables agents to query analytics data directly. Key changes: - Replace mixpanel-browser dep with posthog-js - Rewrite analytics module: mixpanel.ts → posthog.ts - mixpanel.track() → posthog.capture() - mixpanel.identify() → posthog.identify() - mixpanel.register() → posthog.register() - mixpanel.reset() → posthog.reset() - Remove incrementUserProperty (PostHog counts events natively via HogQL) - Env vars: NEXT_PUBLIC_MIXPANEL_TOKEN → NEXT_PUBLIC_POSTHOG_KEY + NEXT_PUBLIC_POSTHOG_HOST - All existing tracking points preserved, same event names and properties