Documentation ¶
Overview ¶
Package swgui provide a http FileSystem handler for swagger UI interface
How to generate asset files:
1. Install tools:
go get -u github.com/shurcooL/vfsgen
2. Generate file:
At root folder, run command:
go generate
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶ added in v1.0.0
type Config struct { Title string `json:"title"` // Title of index file. SwaggerJSON string `json:"swaggerJsonUrl"` // URL to openapi.json/swagger.json document specification. BasePath string `json:"basePath"` // Base URL to docs. ShowTopBar bool `json:"showTopBar"` // Show navigation top bar, hidden by default. HideCurl bool `json:"hideCurl"` // Hide curl code snippet. JsonEditor bool `json:"jsonEditor"` // Enable visual json editor support (experimental, can fail with complex schemas). PreAuthorizeApiKey map[string]string `json:"preAuthorizeApiKey"` // Map of security name to key value. // SettingsUI contains keys and plain javascript values of SwaggerUIBundle configuration. // Overrides default values. // See https://swagger.io/docs/open-source-tools/swagger-ui/usage/configuration/ for available options. SettingsUI map[string]string `json:"-"` }
Config is used for Swagger UI handler configuration.
Directories ¶
Path | Synopsis |
---|---|
Package internal provides internal handler implementation.
|
Package internal provides internal handler implementation. |
Package v3 provides embedded Swagger UI v3 assets.
|
Package v3 provides embedded Swagger UI v3 assets. |
gen
Package main generates legacy assets.
|
Package main generates legacy assets. |
static
Package static contains files to embed.
|
Package static contains files to embed. |
Package v3cdn provides Swagger UI v3 via CDN.
|
Package v3cdn provides Swagger UI v3 via CDN. |
Package v3emb provides Swagger UI v3 with Go embed.
|
Package v3emb provides Swagger UI v3 with Go embed. |
Package v4 provides Swagger UI v4 assets.
|
Package v4 provides Swagger UI v4 assets. |
gen
Package main generates legacy static assets.
|
Package main generates legacy static assets. |
static
Package static contains files to embed.
|
Package static contains files to embed. |
Package v4cdn provides Swagger UI v4 via CDN.
|
Package v4cdn provides Swagger UI v4 via CDN. |
Package v4emb provides Swagger UI v4 with Go embed.
|
Package v4emb provides Swagger UI v4 with Go embed. |
Package v5 provides Swagger UI v5 assets.
|
Package v5 provides Swagger UI v5 assets. |
gen
Package main generates legacy static assets.
|
Package main generates legacy static assets. |
static
Package static contains files to embed.
|
Package static contains files to embed. |
Package v5cdn provides Swagger UI v5 via CDN.
|
Package v5cdn provides Swagger UI v5 via CDN. |
Package v5emb provides Swagger UI v4 with Go embed.
|
Package v5emb provides Swagger UI v4 with Go embed. |
Click to show internal directories.
Click to hide internal directories.