Skip to content

Commit 38a6d80

Browse files
authored
Adding posthog integration for analytics (#141)
1 parent 0870255 commit 38a6d80

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

.github/workflows/preview-docs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ jobs:
1717
id: generate-docs
1818
env:
1919
FERN_TOKEN: ${{ secrets.FERN_TOKEN }}
20+
POSTHOG_PROJECT_API_KEY: ${{ secrets.POSTHOG_PROJECT_API_KEY }}
2021
run: |
2122
OUTPUT=$(fern generate --docs --preview --log-level debug 2>&1) || true
2223
echo "$OUTPUT"

.github/workflows/publish-docs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,5 @@ jobs:
1919
- name: Publish Docs
2020
env:
2121
FERN_TOKEN: ${{ secrets.FERN_TOKEN }}
22+
POSTHOG_PROJECT_API_KEY: ${{ secrets.POSTHOG_PROJECT_API_KEY }}
2223
run: fern generate --docs --log-level debug

fern/docs.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ layout:
8181
tabs-placement: header
8282
searchbar-placement: header
8383
header-height: 80px
84+
analytics:
85+
posthog:
86+
api-key: ${POSTHOG_PROJECT_API_KEY}
87+
endpoint: https://us.i.posthog.com
8488
navigation:
8589
- tab: documentation
8690
layout:

0 commit comments

Comments
 (0)