PolicyEngine / PolicyEngine/policyengine-app-v2
Integrate PostHog analytics and monitoring across Next apps
Open
Nobody has claimed this yet.
- Dominant language
- HTML
- Stars
- 1
- Forks
- 3
- Avg merge
- 1d 50m
- Merged PRs (30d)
- 39
Description
Remaining goal
Complete PostHog analytics and exception monitoring across the Next.js website and calculator-app applications.
Current state
- The website has first-party
/ingestproxy rewrites. - The applications do not install or initialize
posthog-js. - Existing calculator tracking helpers send GA4 events through
window.gtag. - The requested PostHog event schemas, application providers, and client/server exception capture are absent.
Remaining scope
- Initialize PostHog through supported Next.js integration points in both applications.
- Add typed event payloads and instrument the report builder, household builder, calculation lifecycle, report outputs, website calls to action, newsletter signup, research interactions, and country switching.
- Add useful client, route, and server exception capture.
- Add equivalent proxying to the calculator application or document why the website proxy is shared.
- Document required environment variables and verify production builds.
#921 duplicates this issue.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the Next.js integration points in the website and calculator-app, including the existing GA4 tracking helpers and website /ingest proxy rewrites. Map the requested analytics events, providers, exception capture, proxying, and environment variables across both applications. Done means both apps are instrumented, production builds are verified, and the required configuration is documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, next.js
- Domain
- analytics, full-stack, observability
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100