You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The spec-to-code transformation supports the minProperties and maxProperties constraints but the code-to-spec transformation does not. This means that users who use both transformations cannot take advantage of the fix to untyped maps without manually adding the constraints in the generated swagger spec.
Model specification
// swagger:model MyObjectType
// minAttributes: 0 <--- would like to see support for this
type MyObjectType map[string]interface{}
I spent some time in the code trying to figure out how to do this, but it would be more productive if someone can give me some pointers - I'm happy to work on a PR.
Great project!
The text was updated successfully, but these errors were encountered:
Problem statement
The spec-to-code transformation supports the
minProperties
andmaxProperties
constraints but the code-to-spec transformation does not. This means that users who use both transformations cannot take advantage of the fix to untyped maps without manually adding the constraints in the generated swagger spec.Model specification
I spent some time in the code trying to figure out how to do this, but it would be more productive if someone can give me some pointers - I'm happy to work on a PR.
Great project!
The text was updated successfully, but these errors were encountered: