swag
swag copied to clipboard
A way to explicitly include a struct into a definition
Is your feature request related to a problem? Please describe. Is there a way to include a struct into a definition even if it is not mentioned in any controller description? I have an interface{} property in a model, and I would like to include a number of specific structs into a definition for that property, so they can be used from a client side afterwards.
Describe the solution you'd like Something similat to https://goswagger.io/use/spec/model.html maybe.
Describe alternatives you've considered An alternative would ne to add them manually but this is hard when the amount of models is large.
Also need a way to indicate the relation between the definition and the struct field
Also need a way to indicate the relation between the definition and the struct field
I think one possible way is to mention those structs in comments of places where they may be used.