site

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Tags = tags{
	Public:      "Public",
	Private:     "Private",
	PrivateUser: "Private user",
}

Functions

This section is empty.

Types

type APIPage

type APIPage struct {
	Spec         *spec.API
	OrderedPaths []APIPath
}

type APIPath

type APIPath struct {
	APIURL        string
	SiteURL       string
	PathItemProps openAPI.PathItemProps
}

type MethodResponse

type MethodResponse struct {
	Status int
	openAPI.ResponseProps
	ExampleResponse string
}
type Nav []NavItem
func (n *Nav) AppendNavItem(title string, url string, requiresJS bool)
type NavItem struct {
	Name    string
	SiteURL string
	JSOnly  bool
}
func (n NavItem) GetRelativePath(currentPath string) string
func (n NavItem) IsActive(currentPath string) bool

type Page

type Page struct {
	Data interface{}

	Title        string
	Path         string
	TemplateName string
	// contains filtered or unexported fields
}

func (Page) Nav

func (p Page) Nav() Nav

Nav dereferencing the pointer so that the template can iterate over it

type PathMethod

type PathMethod struct {
	openAPI.OperationProps
	Method           string
	OrderedResponses []MethodResponse
}

type PathPage

type PathPage struct {
	Spec       *spec.API
	Path       string
	Methods    []PathMethod
	Parameters []openAPI.Parameter
	APITitle   string
}

type Site

type Site map[string]Page

func NewSite

func NewSite(nav *Nav, APIs spec.APIs, staticRootDir string) *Site

Jump to

Keyboard shortcuts

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