How to link a html document with docfx

942 views Asked by At

We're currently using docfx to generate html documentation for our code.

We have additional html documents we'd link to include.

So far I've included it as a resource section in docfx.json file, and that works, but docfx complains about any link I point to it since it's not aware of it.

Adding the html files under the build section works even less as docfx has no idea what to do with that.

I've also tried creating a xrefmap.yml file to point to my existing html, and it doesn't seem to like having local, relative references.

2

There are 2 answers

0
ESG On BEST ANSWER

I was missing a toc.yml file for the html content.

0
Yuby On

So far I've included it as a resource section in docfx.json file, and that works, but docfx complains about any link I point to it since it's not aware of it.

DocFX is aware of the resource section. You should reference to it like [a resource](resource.html).

I suspect you are using [a resource](resource.md), then a warning is logged as resource.md doesn't exist.