website

package
v0.37.1 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Files = map[string]File{}

Files map is modified by ./generated.go created during ./hack/build.sh

Functions

This section is empty.

Types

type Example

type Example struct {
	ID          string `json:"id"`
	DisplayName string `json:"display_name"`
	Files       []File `json:"files,omitempty"`
}

type File

type File struct {
	Name    string `json:"name"`
	Content string `json:"content"`
}

type Server

type Server struct {
	// contains filtered or unexported fields
}

func NewServer

func NewServer(opts ServerOpts) *Server

func (*Server) Mux

func (s *Server) Mux() *http.ServeMux

func (*Server) Run

func (s *Server) Run() error

type ServerOpts

type ServerOpts struct {
	ListenAddr      string
	RedirectToHTTPS bool
	CheckCookie     bool
	TemplateFunc    func([]byte) ([]byte, error)
	ErrorFunc       func(error) ([]byte, error)
}

Jump to

Keyboard shortcuts

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