docs: add PostHog analytics + fix navbar primary href#54
Conversation
Routes docs page views to the existing arkor.ai / Studio PostHog project so all surfaces share one event stream. Session recording disabled: visitor click/scroll capture is overkill for public docs. Also restore leading slash on navbar.primary.href: Mintlify's local validator rejects bare "quickstart" with "Must be a valid URL or relative path". With the new docs.arkor.ai subdomain, an absolute path stays inside the docs site, so the original /quickstart is fine.
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
Greptile SummaryThis PR makes two targeted changes to Confidence Score: 5/5Safe to merge — changes are a config-only addition with no logic impact. Both changes are correct: the PostHog No files require special attention.
|
| Filename | Overview |
|---|---|
| docs/docs.json | Adds PostHog analytics integration (client-side phc_ key, session recording disabled) and restores the leading slash on navbar.primary.href. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["docs.arkor.ai page load"] --> B["Mintlify runtime"]
B --> C["PostHog JS snippet\n(phc_ project key)"]
C --> D["PostHog Cloud\n$pageview event"]
B --> E["navbar 'Get started' button\nhref: /quickstart"]
E --> F["docs.arkor.ai/quickstart"]
Reviews (1): Last reviewed commit: "docs: add PostHog analytics integration" | Re-trigger Greptile
There was a problem hiding this comment.
Pull request overview
Updates the Mintlify docs configuration to align navigation validation requirements and to send docs pageview analytics into the existing PostHog project used by other Arkor surfaces.
Changes:
- Fix
navbar.primary.hrefto use an absolute path (/quickstart) to satisfy Mintlify validation. - Add a Mintlify
integrations.posthogconfiguration withsessionRecording: false.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
docs/docs.jsonso docs page views land in the same PostHog project as arkor.ai and Studio. One event stream across all surfaces; filter by\$current_urlif separation is neededsessionRecording: false. The visitor click/scroll capture is overkill for public docs, and keeps storage / privacy surface area downnavbar.primary.href(/quickstart). Mintlify's local validator rejects barequickstartwith "Must be a valid URL or relative path". Now that we publish atdocs.arkor.ai(subdomain, notarkor.ai/docssubpath), an absolute path stays inside the docs site so the original form is fineTest plan
pnpm --filter @arkor/docs exec mint validatepasses locally\$pageviewevents fromdocs.arkor.ai(or the Mintlify preview URL)