[GH-ISSUE #8680] Option to copy documentation page link as a raw md file #28483

Closed
opened 2026-04-17 19:55:54 -05:00 by GiteaMirror · 8 comments
Owner

Originally created by @MrLightful on GitHub (Mar 18, 2026).
Original GitHub issue: https://github.com/better-auth/better-auth/issues/8680

Originally assigned to: @ping-maxwell on GitHub.

I would love to see the option to copy link of a documentation page as a raw md file.

My way of working with AI agents has been to reference a link to a documentation of some feature. Usually I prefer a raw md file link. So it contains nothing, but markdown.

So far, working with Better Auth, I am using option to open documentation in Github, and then open raw file, and then copy link, then finally reference in the prompt. Pretty annoying. Instead I would like to have an option, either in LLMCopyButton or ViewOptions, to copy link to a raw md file in Github.

As an example, I have PowerSync documentation, which allows to view page as markdown.

I understand that it is better to just copy-paste the whole markdown with LLMCopyButton, so it avoids tool calls. However, it becomes much less feasible when I want to include multiple documentation pages, in which case I'd prefer just giving the agent all relevant links.

8304f655ab/landing/app/docs/...slug/page.tsx#L72-L75

Originally created by @MrLightful on GitHub (Mar 18, 2026). Original GitHub issue: https://github.com/better-auth/better-auth/issues/8680 Originally assigned to: @ping-maxwell on GitHub. I would love to see the option to copy link of a documentation page as a raw md file. My way of working with AI agents has been to reference a link to a documentation of some feature. Usually I prefer a raw md file link. So it contains nothing, but markdown. So far, working with Better Auth, I am using option to open documentation in Github, and then open raw file, and then copy link, then finally reference in the prompt. Pretty annoying. Instead I would like to have an option, either in `LLMCopyButton` or `ViewOptions`, to copy link to a raw md file in Github. As an example, I have [PowerSync documentation](https://docs.powersync.com/sync/supported-sql), which allows to view page as markdown. I understand that it is better to just copy-paste the whole markdown with `LLMCopyButton`, so it avoids tool calls. However, it becomes much less feasible when I want to include multiple documentation pages, in which case I'd prefer just giving the agent all relevant links. https://github.com/better-auth/better-auth/blob/8304f655ab4636ea7d0a11f19ba3440641922998/landing/app/docs/[[...slug]]/page.tsx#L72-L75
GiteaMirror added the docs label 2026-04-17 19:55:54 -05:00
Author
Owner

@FaryalRizwaan commented on GitHub (Mar 19, 2026):

Hi @Bekacru, can you assign this issue to me? I'd like to work on it!

<!-- gh-comment-id:4089737376 --> @FaryalRizwaan commented on GitHub (Mar 19, 2026): Hi @Bekacru, can you assign this issue to me? I'd like to work on it!
Author
Owner

@bytaesu commented on GitHub (Mar 19, 2026):

Hi @MrLightful,

We already have a "Copy MD" button and provide markdown routes through https://better-auth.com/llms.txt. Could you let me know what you're looking for? 🧐

Image
<!-- gh-comment-id:4089998173 --> @bytaesu commented on GitHub (Mar 19, 2026): Hi @MrLightful, We already have a "Copy MD" button and provide markdown routes through https://better-auth.com/llms.txt. Could you let me know what you're looking for? 🧐 <img width="1352" height="665" alt="Image" src="https://github.com/user-attachments/assets/731c0152-d328-4cb3-8888-80501b8967b3" />
Author
Owner

@bytaesu commented on GitHub (Mar 19, 2026):

Hi @FaryalRizwaan 😁

https://better-auth.com/llms.txt/docs/introduction.md

Looking at this path, it currently renders raw .mdx, so content inside components isn't exposed in the markdown. It would help if the content users see on screen were also cleanly reflected in the markdown, so LLMs can better understand the context.

Would you like to work on this?


Image
<!-- gh-comment-id:4090230289 --> @bytaesu commented on GitHub (Mar 19, 2026): Hi @FaryalRizwaan 😁 https://better-auth.com/llms.txt/docs/introduction.md Looking at this path, it currently renders raw `.mdx`, so content inside components isn't exposed in the markdown. It would help if the content users see on screen were also cleanly reflected in the markdown, so LLMs can better understand the context. Would you like to work on this? --- <img width="596" height="750" alt="Image" src="https://github.com/user-attachments/assets/f8a6e304-73fb-47b1-bd93-37cdf33d3f8e" />
Author
Owner

@FaryalRizwaan commented on GitHub (Mar 19, 2026):

Thanks, that helps @bytaesu. I’m specifically looking for a direct raw .md link per page for easier referencing. If it’s not available, I can take this on

<!-- gh-comment-id:4090244905 --> @FaryalRizwaan commented on GitHub (Mar 19, 2026): Thanks, that helps @bytaesu. I’m specifically looking for a direct raw .md link per page for easier referencing. If it’s not available, I can take this on
Author
Owner

@MrLightful commented on GitHub (Mar 19, 2026):

Looking at this path, it currently renders raw .mdx, so content inside components isn't exposed in the markdown. It would help if the content users see on screen were also cleanly reflected in the markdown, so LLMs can better understand the context.

Not sure what you mean here, @bytaesu, but yeah, I have exactly the same request as @FaryalRizwaan:

I’m specifically looking for a direct raw .md link per page for easier referencing.

Basically i want to copy one md link to one specific feature doc. Not the whole llms.txt. And to do it simply with on-page UI buttons.

Example is in Powersync documentation link. If you trigger similar dropdown, there is option to "View as markdown". That will open a specific markdown page.

<!-- gh-comment-id:4090533426 --> @MrLightful commented on GitHub (Mar 19, 2026): > Looking at this path, it currently renders raw `.mdx`, so content inside components isn't exposed in the markdown. It would help if the content users see on screen were also cleanly reflected in the markdown, so LLMs can better understand the context. Not sure what you mean here, @bytaesu, but yeah, I have exactly the same request as @FaryalRizwaan: > I’m specifically looking for a direct raw .md link per page for easier referencing. Basically i want to copy one md link to one specific feature doc. Not the whole llms.txt. And to do it simply with on-page UI buttons. Example is in Powersync documentation link. If you trigger similar dropdown, there is option to "View as markdown". That will open a specific markdown page.
Author
Owner

@MrLightful commented on GitHub (Mar 19, 2026):

Oh, I see now that format of https://better-auth.com/llms.txt/docs/<path> is easily applicable to all other docs pages, so it already technically works. It's just UI missing a button that either opens this page or copy the link to it.

@FaryalRizwaan an open-source contributor advise: if you want to take on the issue, you can just do it. You don't have to ask for permission. Draft a pr, then ppl will review it. ;)

<!-- gh-comment-id:4090550398 --> @MrLightful commented on GitHub (Mar 19, 2026): Oh, I see now that format of `https://better-auth.com/llms.txt/docs/<path>` is easily applicable to all other docs pages, so it already technically works. It's just UI missing a button that either opens this page or copy the link to it. @FaryalRizwaan an open-source contributor advise: if you want to take on the issue, you can just do it. You don't have to ask for permission. Draft a pr, then ppl will review it. ;)
Author
Owner

@bytaesu commented on GitHub (Mar 19, 2026):

@MrLightful Got it!


@FaryalRizwaan You can take this on if you'd like. It may involve design concept, so I might follow up with some tweak commits!

<!-- gh-comment-id:4091072595 --> @bytaesu commented on GitHub (Mar 19, 2026): @MrLightful Got it! --- @FaryalRizwaan You can take this on if you'd like. It may involve design concept, so I might follow up with some tweak commits!
Author
Owner

@FaryalRizwaan commented on GitHub (Mar 19, 2026):

Thanks @bytaesu! I'll start working on it and open a PR soon.

<!-- gh-comment-id:4091465045 --> @FaryalRizwaan commented on GitHub (Mar 19, 2026): Thanks @bytaesu! I'll start working on it and open a PR soon.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#28483