Skip to content

Instantly share code, notes, and snippets.

@justinyoo
Last active February 22, 2016 00:11
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save justinyoo/8029b36c6787b4d6f590 to your computer and use it in GitHub Desktop.
ASP.NET Core Tips & Tricks
var config = new HttpConfiguration();
config.EnableSwagger(
c =>
{
c.SingleApiVersion("v1", "Swagger UI");
c.IgnoreObsoleteActions();
c.IgnoreObsoleteProperties();
c.IncludeXmlComments(GetXmlCommentsPath());
c.DescribeAllEnumsAsStrings();
c.UseFullTypeNameInSchemaIds();
})
.EnableSwaggerUi(
c =>
{
c.DocExpansion(DocExpansion.List);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment