Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
    Apparently I need to enable xml comments in my project.
    I am still having issues.
    Bill Hertzing
    Using docfx 2.57.2, it is not generating documentation for the new c# 9.0 records. Known issue?
    Bill Hertzing
    I see that dotnet/docfx#7191 asks the same question, was opened 2021-03-14, and has had no response....
    Thomas Ibel
    I'm facing dotnet/docfx#7406 too. Any chance we get a new release in the next hours/days?
    can you add a custom 404 page?
    Bill Hertzing
    The site RealFaviconGenerator.net will create 10 files that ensures our documentation site has all the files needed to support favicon across many browsers. These 10 files have to be installed into the root of the documentation site. To keep the source repository cleanly organized, I'd like to store these 10 files in <reporoot>/assets/siteroot. Can DocFx copy the contents of <reporoot>/assets/siteroot into <reporoot>/_site during document generation? and if so, could someone share the .docfx snippet(s) necessary to accomplish it? Thanks!
    Hello. I have a code generation tool which processes PLC code to C# and I'm using docfx to generate documentation ..The problem is that the code generation tool will not generate a an object of type "UINT" but of type "System.Object" ...there's a a PLC type in the description part though... Do you think it is possible to write a plugin, which will parse the description and edit the type value? so I get Type : UIT, Description : Twin type UInt
    Hello, Is there a way to have the same rendering using <see langword="null"/> and <c>null</null> or better with a link like in this page https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/strings/ which link the null keyword to the documentation ?
    I did it directly with the source code. Goodbye!
    Using docfx 3, is there a example file on how to link projects to be documented? Have been looking in th v3 branch for references but could not find anything I was looking for. Thanks
    1 reply
    David Márquez Fàbrega
    Are plugins already supported in the v3-release branch? I suppose now they will have to be written for the markdig processor no?

    Hi all, I am busy documenting a multi project solution. I have managed to generate the required .yml files in a separate folder for each project, however, some of the projects make reference to the same classes in an other shared project resulting in some nasty warnings:

    Warning:[BuildCommand.BuildCore.Build Document.LinkPhaseHandlerWithIncremental.ManagedReferenceDocumentProcessor.Save](ProjectA_sdk/ProjectB.Provider.Models.yml)Uid(ProjectB.Provider.Models) has already been defined in ProjectB-plugins/ProjectB.Provider.Models.yml.

    Now I have tried several different variations of the exclude semantics inside of the src section within the docfx.json file but these files will just not be excluded. Sample of the excludes I have tried:

    "exclude": [

    Is there anything I am missing W.R.T this exclude section? If not the next avenue I will explore is the Filtering of Unwanted APIs.

    Morten Nielsen

    @BrettGFleischer It shouldn't be a problem if you just merge the two generated TOC's above with a new toc. ie:

     "metadata": [
          "src": [
              "files": [
              "src" : "../../../src/"
          "dest": "../../../../../output/docs/api/Common",
          "properties": { "TargetFramework": "net6.0" },
        }, {
          "src": [
              "files": [
              "src" : "../../../src/"
          "dest": "../../../../../output/docs/api/Common.Utilities",
          "properties": { "TargetFramework": "net6.0" },

    Then above the two output folders, create a toc.yml with something like this:

    - name: Common
      href: Common/toc.yml
    - name: Common.Utilities
      href: Common.Utilities/toc.yml

    This root folder is what you'll point the build to

    1 reply
    hey, how can I make docfx listen to the DefineConstants property ? I keep trying to define UNITY_EDITOR but it isn't generating those files
    Max Inno
    Hello. Is it possible to set default page instead of generating almost empty index.html? I would like make generated page from README.md as default
    Since i didnt end up getting any help with adding scripting defines in non-csproj projects, I decided to make a csproj and do it that way
    however, I am getting this error now:
    [22-07-05 02:56:24.369]Warning:[MetadataCommand.ExtractMetadata](D:/Users/Lachee/Documents/Unity Projects/lachee-utilities/Packages/com.lachee.utilities/Docfx.csproj)Workspace failed with: [Failure] Msbuild failed when processing the file 'D:\Users\Lachee\Documents\Unity Projects\lachee-utilities\Packages\com.lachee.utilities\Docfx.csproj' with message: Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
    <Project Sdk="Microsoft.NET.Sdk">
        <Compile Include="Scripts/**/*.cs" />
        <Compile Remove="**/*.meta" />
        <None Remove="**/*.meta" />
        <Compile Remove="**/*.asmdef" />
        <None Remove="**/*.asmdef" />
        <Compile Remove="Documentation~\**" />
        <None Remove="Documentation~\**" />
        "metadata": [
                "src": [
                        "src": "..",
                        "files": [
                "dest": "api"
    Rhys van der Waerden
    Is it possible to format primitives but their more recognized alias? E.g. float instead of System.Single
    Calvin Wilkinson
    Hello everybody. I am new to docfx and I need to create a doc site that shows API documentation for different versions of my api. I have been looking for a way to do it and I cannot find a way or any tutorials. I know it doesn't do it out of the box and 3.0 which is in beta will provide that feature, but I need something until 3.0 is released. Any advice or resources on this would be awesome!!
    Something simular to what docs.unity3d.com does
    Ahmed Yasin Koculu
    Hi everybody,
    I am trying to create a doc for my open source project https://github.com/koculu/ZoneTree
    using https://github.com/dotnet/docfx/releases/tag/3.0.0-beta1.1235%2Bf5a62adcac
    I created the configuration based on https://github.com/docascode/template/tree/main/samples
    I use
    dotfx build
    dotfx serve
    My problem is, the API reference is not getting created.
    Could you please give some pointer to create metadata with v3? Shall I use v2.59 dotfx metada command to create API reference yml's?
    I also tried that but created metadata yml seems like incompatible with v3.
    Calvin Wilkinson
    Ok so I have made some progress. I originally was pointing to a project file using "src/**.csproj". This was not working. I changed to "src/**.cs" and now it is working. Reading the docs tells me that it depends on VS2017 to be installed on the machine for project based metadata generation. I have VS2022 though. 🤷🏼
    Samira Maleki
    Hi everybody,I need to custom TripleSlashCommentModel to expose the new tag, then render but, how do I use the class library in the docfx after changed
    Here is the code: https://github.com/dotnet/docfx/blob/dev/src/Microsoft.DocAsCode.Metadata.ManagedReference.Common/Parsers/TripleSlashCommentModel.cs
    @superyyrrzz @rhys-vdw @tkopacz @idargb @furier @superyyrrzz @bloudraak @tgaldi @henkmeulekamp @vinhui

    Hi, I'm setting up a docs pipeline for TypeScript using https://api-extractor.com/ and DocFX. I tried the tool on this page before deciding to use API-Extractor but was unsuccessful: https://dotnet.github.io/docfx/tutorial/universalreference/gen_doc_for_ts.html

    Is there a reason API extractor isn't the recommendation on this page? It seems to be the tool officially used by microsoft but I can't find much resources about setting up a pipeline using it.

    Mark Vincze

    Hey folks,

    Is it okay to ask questions related to docfx issues here?

    I'm building documentation with docfx for a .NET Core solution (the projects are targeting net5.0 and net6.0).
    I'm doing this on Linux in a Docker container, the container is based on mcr.microsoft.com/dotnet/sdk:6.0, and has a couple of extra things:

    • Mono is installed
    • nuget.exe is downloaded
    • The packages docfx.console and SQLitePCLRaw.core are installed with nuget

    When I try to build the docs by running

    mono ./docfx/docfx.console/tools/docfx.exe ./docs/docfx.json

    The documentation is built, but there are two Warnings in the output that I'm trying to chase down.
    I'm getting these:

    [22-12-13 03:48:42.333]Warning:[MetadataCommand.ExtractMetadata](/app/src/MySolution/MySolution.Common.csproj)Workspace failed with: [Failure] Msbuild failed when processing the file '/app/src/MySolution/MySolution.csproj' with message: /usr/lib/mono/msbuild/15.0/bin/Microsoft.Common.CurrentVersion.targets: (1232, 5): The reference assemblies for ".NETFramework,Version=v6.0" were not found. You might be using an older .NET SDK to target .NET 5.0 or higher. Update Visual Studio and/or your .NET SDK.

    Yet the SDK seems to be installed if I check it with dotnet:

    dotnet --list-sdks
    6.0.403 [/usr/share/dotnet/sdk]

    Or to make it work with Mono I need some extra config?
    And the other error I'm constantly seeing in the output is this:

    [22-12-13 03:48:50.131]Warning:[MetadataCommand.ExtractMetadata](/app/src/MySolution/MySolution.csproj)Workspace failed with: [Failure] Msbuild failed when processing the file '/app/src/MySolution/MySolution.csproj' with message: /usr/lib/mono/msbuild/15.0/bin/Microsoft.Common.CurrentVersion.targets: (1733, 5): The "GetReferenceNearestTargetFrameworkTask" task failed unexpectedly.
    System.MissingMethodException: Method not found: NuGet.Frameworks.NuGetFramework NuGet.Frameworks.NuGetFramework.ParseComponents(string,string)
      at NuGet.Build.Tasks.GetReferenceNearestTargetFrameworkTask.Execute () [0x00142] in <284aae14d5034455899563954b017376>:0
      at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute () [0x00029] in <3fa5db086dc941c1a57d0f5b812004f0>:0

    Anybody has any ideas what these might be caused by?
    The Dockerfile for the image in which I'm trying to do this build looks like this:

    FROM mcr.microsoft.com/dotnet/sdk:6.0
    RUN apt update && \
        apt install -y apt-transport-https dirmngr && \
        apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
        echo "deb https://download.mono-project.com/repo/debian stable-buster main" | tee /etc/apt/sources.list.d/mono-official-stable.list && \
        apt update && \
        apt install -y mono-devel mono-runtime msbuild curl && \
        curl -o /usr/local/bin/nuget.exe https://dist.nuget.org/win-x86-commandline/latest/nuget.exe && \
        echo '#!/bin/bash\nmono /usr/local/bin/nuget.exe "$@"' > /usr/bin/nuget && \
        chmod +x /usr/bin/nuget