This question is the same as this question. But the OP answered his own question and it didn't help me.
I am trying to create a documentation similar to the Docfx site:
However, when I build the project, I get the index.html that looks like this:
My configuration is this:
My folder configuration is:
+MyApp.sln
|-MyApp
MyApp.csproj
docfx.json
toc.yml
index.md
|-_site
|- api
index.md
toc.yml
|-articles
intro.md
toc.md
I can see that all the files are generating, but the TOC does not get put on to the index.html. The Docfx tutorial is not very helpful since it hasn't been upgraded to the newest version. For instance, docfx init
does not run, I have to use docfx new conceptual
. I have tried:
docfx new conceptual
from a command prompt in the same directory as the docfx.jsondocfx build
from a command prompt in the same directory as the docfx.jsondocfx serve _site --port 8182
from the same directory. However, when this is done, my browser tells me to check my proxy settings.In everything I tried to do, I may have upgraded my docfx version in one place, but not in Visual Studio because when running docfx serve
I get the following Content root path:
But I am unsure of how to revert or if I need to.
I'm definitely in a locked-down security environment and I suspect that has something to do with it. Does anyone know of how what files I can alter, if any, to get the TOC on the same page as the index.html? I don't mind writing this by hand, if needed, if I'll only need to do it once in a configuration file.
I finally found the problem. The issue for me was the folder configuration. I had to move my docfx.json
, toc.yml
, and index.md
to the top level where my .sln file was because it was accessing multiple .csproj
files. I didn't realize that the top-level toc.yml
could only access folders under it's current location.
Furthermore, the top-level toc.yml
will only create the menu items across the top of the page. The lower-level toc files will create the TOC on the left side of the page.
It took some digging into the tutorial to figure this out.