Which scope/s are relevant/related to the feature request?
Docs
Information
Add a "Copy page" split-button/dropdown to the header of each docs page (next to the page title), following the pattern popularized by other framework docs sites. The dropdown would offer:
- Copy page as Markdown — copies the page's raw Markdown source to the clipboard, useful for pasting into LLMs, issues, and discussions with formatting intact.
- View as Markdown — opens the raw Markdown for the page at a stable URL, e.g.
https://analogjs.org/docs/<slug>.md.
This makes docs content easy to feed into AI assistants and to reference/quote elsewhere, and the .md URLs pair naturally with llms.txt conventions.
Implementation notes
- The copy action is nearly free: docs pages already receive the raw Markdown client-side via
injectContent() (doc.content is the Markdown string), so it's a navigator.clipboard.writeText() call plus a small standalone component. Frontmatter would be stripped, prepending # {title} instead.
- The component follows the existing docs theme and patterns: a standalone component in
src/app/docs/components/ styled with Tailwind utilities and the docs theme CSS variables (--border, --fg-muted, etc.), consistent with existing components like the theme toggle and locale picker, and working in both light and dark themes.
- The view as Markdown action emits the raw
.md files as static assets at /docs/<slug>.md during the existing prerender step. Localized pages (/es/docs/..., /de/docs/...) resolve to their localized source.
- The dropdown leaves room for future entries (e.g. "Open in ChatGPT/Claude" deep links), out of scope initially.
Prior art
Describe any alternatives/workarounds you're currently using
Manually copying rendered HTML from the browser (loses formatting/code fences) or finding the source .md in the GitHub repo by hand.
I would be willing to submit a PR to fix this issue
Which scope/s are relevant/related to the feature request?
Docs
Information
Add a "Copy page" split-button/dropdown to the header of each docs page (next to the page title), following the pattern popularized by other framework docs sites. The dropdown would offer:
https://analogjs.org/docs/<slug>.md.This makes docs content easy to feed into AI assistants and to reference/quote elsewhere, and the
.mdURLs pair naturally with llms.txt conventions.Implementation notes
injectContent()(doc.contentis the Markdown string), so it's anavigator.clipboard.writeText()call plus a small standalone component. Frontmatter would be stripped, prepending# {title}instead.src/app/docs/components/styled with Tailwind utilities and the docs theme CSS variables (--border,--fg-muted, etc.), consistent with existing components like the theme toggle and locale picker, and working in both light and dark themes..mdfiles as static assets at/docs/<slug>.mdduring the existing prerender step. Localized pages (/es/docs/...,/de/docs/...) resolve to their localized source.Prior art
.mdversions of every docs page..mdper content page (/raw/<path>.md).Describe any alternatives/workarounds you're currently using
Manually copying rendered HTML from the browser (loses formatting/code fences) or finding the source
.mdin the GitHub repo by hand.I would be willing to submit a PR to fix this issue