Skip to content
Pavel Novikov edited this page Feb 27, 2017 · 3 revisions

Reinforced.Typings supports export of XMLDOC documentation for your C# types and members transpliting it to JSDOC automatically. To export documentation for your types you have to:

  1. Enable output of XML documentation for your project. To do that in Visual Studo:
    1. Navigate to your project's property pages (RMB on project -> Properties...)

    2. Go to "Build" tab

    3. Under "Output" section check tickbox "XML documentation file"

    4. Press Ctrl-S or save button on toolbar

      Also, default Visual Studio project settings provide XML documentation generation automatically when you switch your solution configuration from "Debug" to "Release".

  2. Set RT's global settings parameter GenerateDocumentation to true. It can be done either using [TsGlobal] attribute or corresponding fluent call inside .Global
  3. Rebuild your project.
  4. Check your output files

Adding additional documentation path

Reinforced.Typings obtains path to your XMLDOC documentation file during build from corresponding MSBuild's property ($(MSBuildProjectDirectory)\$(DocumentationFile)). So it is not necessary to specify documentation file path explicitly for your project.

In case if you export types from 3rd-party assembly and want to promote documentation from it you can add additional documentation lookup path. This option is available only for fluent configuration. To do it, use .TryLookupDocumentationForAssembly method of your ConfigurationBuilder. Parameters of .TryLookupDocumentationForAssembly are:

  • assmbly (System.Reflection.Assembly): points to assembly you want to look up documentation for. Reinforced.Typings will try to automatically lookup this assembly's path for corresponding .xml file. In most cases it is enough
  • documentationFileName (string): options. If desired assembly's XMLDOC file has different name than Assembly.Name.xml then you can provide absolute or relative path to documentation file through documentationFileName parameter. In case of relative path, documentation file will be searched in the directory of assmbly - the first parameter.