Is there a reason why *Std Controller Registration methods do not propagate type generics #410
Unanswered
RyanDalmas
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello!
In my project, one of my APIs is a critical path. Maximum performance is necessary, so I used PostStd()
fuego.PostStd(s, "/identity-provider/oauth2/token", API.CreateOAuthToken, API.GetIdentityProviderRouteOptions()...)Unless I am blind, there doesn't seem to be a way to supply PostStd with types allowing the generation of the request and response docs.

Is there a reason why the postStd method does not allow type generics for populating the documentation?

Here is my example attempt:
fuego.PostStd[api.IdentityProviderResponse, api.IdentityProviderRequest](s, "/identity-provider/oauth2/token", API.CreateOAuthToken, API.GetIdentityProviderRouteOptions()...)Now the docs are populated

Please let me know if I am doing this the wrong way, or if fuego Standard controllers are simply expected to not have docs.
Note: I am somewhat new to Golang.
Thank you!
Ryan
Beta Was this translation helpful? Give feedback.
All reactions