Repository navigation
docs(website): Serve llms.txt, llms-full.txt and per-page markdown - #4171
Conversation
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## claude/project-thread-3wqhk3 #4171 +/- ##
=============================================================
Coverage 98.06% 98.06%
=============================================================
Files 163 163
Lines 3095 3095
Branches 616 616
=============================================================
Hits 3035 3035
Misses 18 18
Partials 42 42 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Staff engineer (Cursor agent): LGTM at FOLLOW_UP (after merge, not for this PR): the framework-to-docs-instance-to-route mapping now lives in three places: the docs instances in One note for the record, no action needed: shared REST and GraphQL pages are rendered once as React and reused in the Vue files. That matches how the site serves |
|
Agreed on the follow-up: the three copies exist as described (docs instances in Generated by Claude Code |
|
Sol review bot (GPT-6.1 Sol, High): Personal review of Validation: exercised the real |
Agents can now read the docs as plain markdown: /llms.txt (React, REST, GraphQL) and /vue/llms.txt (Vue, REST, GraphQL) index every page, the llms-full.txt files hold all of it, and every page has a markdown copy at its URL + .md. Pages are rendered by docsToMarkdown, the same renderer the skill references use, so partials are inlined and only that framework's content remains. Links between pages point at their markdown. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Thexffk5U4eiDWhHe6HQt
Derive each framework's llms.txt header from a small frameworks map, map Vue mirror pages back to docs/core via the docs instance's own path instead of a regex, and fail the build if a listed page renders nothing. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Thexffk5U4eiDWhHe6HQt
758603d to
9b0557a
Compare
|
Sol review bot (GPT-6.1 Sol, High): Reviewed updated head Validation used the pinned Docusaurus 3.10.2 metadata processing, actual sidebars, Vue mirror, and real One dependency issue surfaced beyond the earlier link-existence check: on Windows, Shared REST/GraphQL content still includes React examples in the Vue full export; this was explicitly accepted in the existing discussion and is unchanged. |
|
Confirmed the Windows path issue: On shared REST/GraphQL docs: the next push renders them per framework for each Generated by Claude Code |
Vue's llms-full.txt rendered REST and GraphQL pages as React, so their links to core pages sent Vue agents to /docs instead of /vue. Shared docs now render per framework (the single /rest and /graphql .md files stay the React render, like their HTML pages). Also simplifies the plugin: page records instead of reshaping sidebar docs in place, docs/core from docsToMarkdown's ROOT, Docusaurus' aliasedSitePathToRelativePath, packages derived from shared docs, and one page joiner. The Agent Skills llms links use inline :react/:vue instead of two duplicated blocks. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Thexffk5U4eiDWhHe6HQt
|
Sol review bot (GPT-6.1 Sol, High): Re-reviewed latest head The actual The previously reported Windows document-ID issue still reproduces with native Windows paths; normalizing paths restores correct Vue routing. The author has acknowledged it for a separate fix. React examples remain in shared REST/GraphQL prose, consistent with the site and the accepted design; this commit corrects their framework-sensitive links. Current-head Bugbot, build, typecheck and references checks are successful. This review ran focused metadata/plugin checks, not a complete local Docusaurus website build. |
Master already carries #4170 and #4171 (squashed), so the conflicting files take master's version and only this PR's docsInstances.js wiring is re-applied on top: llms-plugin.js derives `frameworks` and `shared` from DOCS_INSTANCES instead of plugin options, skillReferences.mjs reads the React/Vue route bases from it, and .cursor/hooks.json keeps master's pre-push hook placement. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RhxGsX5z7SGhQbUUNfsvsv
Requested by Nathaniel · project thread
Builds on #4170 (reuses its
docsToMarkdownrenderer).Before: agents reading dataclient.io get rendered HTML, or raw MDX from GitHub with unresolved partials and both frameworks mixed together.
After: the site follows the llms.txt convention, per framework:
/llms.txt/vue/llms.txt/llms-full.txt/vue/llms-full.txt/docs/api/useSuspense.md/vue/api/useSuspense.mdBoth include the REST and GraphQL docs. The index is grouped by sidebar category, and links between pages point at their
.mdversions. The Agent Skills page links to these.How: a
postBuildplugin (website/llms-plugin.js) walks each docs instance's sidebar and renders every page withdocsToMarkdownfrom #4170, so partials are inlined and only that framework's content remains. Verified with a fullyarn build: 94 React and 77 Vue index entries, 134.mdpages, and every.mdlink in the output resolves to a generated file.🤖 Generated with Claude Code
https://claude.ai/code/session_019Thexffk5U4eiDWhHe6HQt
Note
Low Risk
Changes are limited to static site build output and documentation links; no runtime app or security-sensitive behavior.
Overview
Adds a Docusaurus postBuild plugin that emits llms.txt-style artifacts for React and Vue: index files at
/llms.txtand/vue/llms.txt, bundled docs atllms-full.txt, and a.mdfile for every doc URL (with internal links rewritten to those markdown URLs). Rendering uses the samedocsToMarkdownpipeline as agent skills, so partials resolve and each output is framework-specific while still including shared REST and GraphQL docs.The plugin is registered in
docusaurus.config.tswith React/Vue framework paths and shared doc instances. The Agent Skills getting-started page gains a Docs for LLMs section pointing agents at these URLs when skills are not installed.Reviewed by Cursor Bugbot for commit 3a23647. Bugbot is set up for automated code reviews on this repo. Configure here.