Settings

Theme

Show HN: Go framework with builtin OpenAPI support

github.com

8 points by ck_one 2 years ago · 2 comments

Reader

ttymck 2 years ago

This looks really useful. I look forward to test driving it.

Just from the Readme, I have one question. It looks like it's necessary to register a hook to start serve the router. Is there a use case for _not_ registering that hook?

  • danielgtaylor 2 years ago

    Not really. 99% of the time you would register the start hook, and it's a good idea to register a stop hook as well. Keep in mind the CLI is completely optional so if you already use the built-in option parsing or Cobra or something else you can keep using that.

    I guess if for example you were just using Huma to generate OpenAPI from some Go code and dump that to the terminal or a file you might skip the start hook.

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection