Open AchoArnold opened 3 years ago
I agree, this would be super helpful. Especially now that we have record types, so for positional records it isn't super feasible to add XML docs in a minimalistic manner.
To me, an "example" doesn't have exact correlation with a "default value". But, you can use the existing DefaultValueAttribute
to kind of achieve this, I think (assuming I am understanding the OP).
See here.
Thanks for contributing to Swashbuckle.AspNetCore! As per the contributing guidelines, please adhere to the following rules of thumb before submitting your issue:
It would be nice to have an annotation for an example property. Perhaps we could add it to
[SwaggerSchema]
? I know currently you can add the example using XML.