Skip to content

Document on-page feedback logging for self-hosted deployments#4504

Merged
thesandlord merged 4 commits into
mainfrom
fern/document-feedback-logs
Mar 23, 2026
Merged

Document on-page feedback logging for self-hosted deployments#4504
thesandlord merged 4 commits into
mainfrom
fern/document-feedback-logs

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Mar 23, 2026

Copy link
Copy Markdown
Contributor

Summary

Documents where on-page feedback events appear in self-hosted deployments. Changes across four files:

  • self-hosted.mdx: Updated feature support table to mark "On-page feedback" as supported (was "No") and linked to the new setup docs.
  • self-hosted-set-up.mdx: Added new "On-page feedback" section documenting the [fern-docs-feedback] log prefix, tracked events (feedback_voted, feedback_submitted, code_block_feedback_submitted), properties, and a docker logs filtering example.
  • user-feedback.mdx: Added an Info callout pointing self-hosted users to the new docs.
  • changelog/2026-03-23.mdx: Added changelog entry for on-page feedback logging in self-hosted deployments.

Based on the implementation in packages/fern-docs/bundle/src/components/analytics/track.ts in fern-platform, which emits structured JSON via console.info with the [fern-docs-feedback] prefix when NEXT_PUBLIC_IS_SELF_HOSTED=1.

Review & Testing Checklist for Human

  • Verify "container stdout" claim is accurate. The code in track.ts calls console.info() inside a client-side guard (typeof window === "undefined" returns early). This means logs may go to the browser console rather than Docker container stdout. If so, the documentation, feature table entry, changelog entry, and docker logs example are all misleading and need correction. This is the highest-priority item.
  • Confirm with engineering (Sandeep mentioned support was added in tag 0.111.1) whether there is additional server-side logging not captured in track.ts, or whether the intent is browser-console logging only.
  • Verify the anchor link /learn/docs/self-hosted/set-up#on-page-feedback resolves correctly in the preview.
  • Check the changelog preview renders correctly.

Notes

The Slack thread that prompted this had Denis reporting he couldn't see feedback in the logs despite running the correct container version. This could be because the logging is browser-side only, or there may be a bug. The documentation should accurately reflect what actually happens — worth confirming before merging.

Link to Devin session: https://app.devin.ai/sessions/d32688870d894f058413f6c80fea90c1

Co-Authored-By: bot_apk <apk@cognition.ai>
@devin-ai-integration devin-ai-integration Bot requested a review from devalog as a code owner March 23, 2026 16:05
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@fern-api

fern-api Bot commented Mar 23, 2026

Copy link
Copy Markdown
Contributor

Requested by: sandeep
Slack thread: View conversation


### Filtering logs

To extract feedback events from your container logs, filter for lines containing the `[fern-docs-feedback]` prefix:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[Microsoft.Wordiness] Consider using 'remove' instead of 'extract'.

@github-actions

github-actions Bot commented Mar 23, 2026

Copy link
Copy Markdown
Contributor


## On-page feedback logging for self-hosted deployments

Self-hosted deployments now log [on-page feedback](/learn/docs/user-feedback) events as structured JSON with the `[fern-docs-feedback]` prefix. Filter your container logs to capture user feedback, including thumbs up/down votes and written messages.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [vale] reported by reviewdog 🐶
[FernStyles.Current] Avoid time-relative terms like 'now' that become outdated

@thesandlord thesandlord merged commit 516c351 into main Mar 23, 2026
2 checks passed
@thesandlord thesandlord deleted the fern/document-feedback-logs branch March 23, 2026 17:20
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.

3 participants