I'm trying to set up the ASP.NET Help Pages to run in an existing MVC project, though pointing towards the documentation file from a Web API project in the same solution. Convention has the Help Pages running inside the Web API that it's documenting but in this case I want it in a sibling MVC project.
The Web API project outputs its documentation XML file in a folder within the MVC project.
I've installed the Microsoft.AspNet.WebApi.HelpPage NuGet package in the MVC project. This creates a class \Areas\HelpPage\App_Start\HelpPageConfig.cs
, and within this class's Register
method I've passed the XmlDocumentationProvider
the path to the Web API's documentation file.
But when I load the page, it's empty, aside from a title and a placeholder description.
Upon debugging the HelpController.Index
method, I can see in the returned IApiExplorer
that the _apiDescriptions
are empty.
However, if I install the Help Pages directly into the Web API project and debug the same method, I can see that the _apiDescriptions
are now present.
Can anyone explain what the Web API project is doing or has configured which the MVC project isn't doing or hasn't configured?