Skip to content

feat: add PostHog analytics for macOS and Windows#38

Open
Aryansharma28 wants to merge 2 commits intomainfrom
feat/posthog-analytics
Open

feat: add PostHog analytics for macOS and Windows#38
Aryansharma28 wants to merge 2 commits intomainfrom
feat/posthog-analytics

Conversation

@Aryansharma28
Copy link
Contributor

Summary

  • Add PostHog DAU and session tracking for both macOS (Swift SDK) and Windows (posthog-js)
  • Add per-action metrics (card_created, card_moved, card_deleted, etc.) to measure feature demand
  • macOS uses BoardStore.onAction callback to avoid adding PostHog dependency to core library
  • Windows uses inline capture() calls in Zustand store actions

Test plan

  • Verify macOS app sends app_opened event on launch
  • Verify Windows app sends app_opened event on launch
  • Perform card actions and verify events appear in PostHog
  • Confirm no analytics sent when API key is placeholder

Aryansharma28 and others added 2 commits March 9, 2026 15:39
macOS: PostHog Swift SDK, initialized on app launch, captures app_opened.
Windows: posthog-js, initialized on mount, captures app_opened.
Both send platform tag for segmented DAU. PostHog handles session
duration and retention automatically. API key placeholder needs replacing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
macOS: BoardStore.onAction callback maps actions to events — card
created/launched/moved/deleted/archived, terminal, queued prompts,
linking, search, project filter.

Windows: capture() calls in Zustand store actions and onboarding
wizard — same event names for cross-platform comparison.

Events: app_opened, card_created, card_launched, card_moved,
card_deleted, card_archived, card_renamed, card_selected,
terminal_created, queued_prompt_added/sent/removed,
search_opened, search_query, settings_opened, new_task_opened,
project_filtered, onboarding_step, onboarding_completed.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant