Documentation
¶
Overview ¶
Package gendoc provides a turnkey main for generating a Registry's OpenAPI document from the command line, so an application's generator command is a single line:
//go:generate go run ./cmd/openapi-gen -out ./openapi
package main
import (
"github.com/antlss/oapi/tools/gen_doc"
"example.com/app/api"
)
func main() { gendoc.Main(api.Registry()) }
Flags: -out DIR, -format LIST (json,yaml), -base FILE, -no-validate.
It lives under tools/ alongside any future code generators (e.g. an API mock generator), each a small package that wraps the core library.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.