Help us shape the future of Go! Take the 2026 Go Developer Survey

docs

package
v0.3.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 11, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package docs provides reusable HTTP handlers for serving OpenAPI specs and Redoc UI documentation pages.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RedocHandler

func RedocHandler(specURL, title string) http.HandlerFunc

RedocHandler returns an http.HandlerFunc that serves a Redoc UI page pointing at the given spec URL.

func SpecHandler

func SpecHandler(spec []byte) http.HandlerFunc

SpecHandler returns an http.HandlerFunc that serves a raw OpenAPI JSON spec.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL