Skip to content

[repo-assist] docs: document embedding images in XML/Markdown doc comments - #1332

Draft
github-actions[bot] wants to merge 1 commit into
mainfrom
repo-assist/docs-apidocs-images-20260917-cf06cab738562775
Draft

github-actions[bot] wants to merge 1 commit into
mainfrom
repo-assist/docs-apidocs-images-20260917-cf06cab738562775

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

🤖 This PR was created by Repo Assist, an automated AI assistant.

Summary

Documents how to embed images in XML/Markdown /// doc comments in docs/apidocs.fsx. This behaviour previously had no documentation anywhere in the repo — it was only explained ad hoc by a Repo Assist comment on issue #928.

Verified against current code (src/FSharp.Formatting.ApiDocs/SymbolReader.fs, src/fsdocs-tool/BuildCommand.fs): fsdocs never copies source-tree images referenced from /// doc comments, since it has no way to resolve a path relative to the source file. The documented workaround (place images under the docs input directory, e.g. docs/content/images/, and reference them with a site-root-relative /content/images/... path) matches the actual copy/substitution behaviour. Cross-references the existing --saveimages docs for the separate literate .fsx script image pipeline, which behaves differently (path-relative resolution).

Changes

  • docs/apidocs.fsx: added an "Images in Doc Comments" section under "Classic XML Doc Comments" / before "Markdown Comments".
  • RELEASE_NOTES.md: added an [Unreleased] entry.

Test Status

  • dotnet fantomas build.fsx src tests docs --check — clean (docs .fsx files are .fantomasignored, no formatting issues).
  • ✅ Built fsdocs-tool (Release) and ran fsdocs build --input docs against the updated docs/apidocs.fsx — content generation succeeded (18 pages), and the generated apidocs.html contains the new "Images in Doc Comments" section rendered correctly.
  • No code changes, so no test suite run was needed.

Relates to #928 (does not close it — the underlying feature request for automatic image copying from XML doc comments is still open; this PR only documents the current, correct workaround).

Generated by 🌈 Repo Assist, see workflow run. Learn more.
Comment /repo-assist to run again

Add this agentic workflow to your repo

To install this agentic workflow, run

gh aw add githubnext/agentics/workflows/repo-assist.md@4bc8419fad05e6b032741cbfd189986700bcf71c

Closes long-standing confusion tracked in issue #928 (fsdocs does not
copy source-tree images referenced from XML/Markdown /// doc comments;
it only resolves such assets from the docs input directory using
site-root-relative paths). Adds a verified 'Images in Doc Comments'
section to docs/apidocs.fsx cross-referencing the existing
--saveimages pipeline for literate .fsx scripts.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants