huma
huma copied to clipboard
Add alias for empty input/output payload.
trafficstars
Hi! I would like to suggest adding a new type alias for empty input/outputs. Right now, if a route does not accept any input and/or output, it should be defined as a pointer to an empty structure. In my project I have a separate type alias for this as it is more convenient and clearer, so I thought it might be nice to have it built-in (e.g. huma.Empty, huma.EmptyPayload).
If you think this can be helpful, I'd like to contribute.
@kvizyx thanks for opening an issue! I think it this increases readability then I'd be happy to add it. Feel free to create a PR!