ui

package
v0.0.0-...-09e780c Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(path string) http.Handler

Types

type BoolSetting

type BoolSetting func() bool

type Handler

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

func NewUIHandler

func NewUIHandler(opts *Options) *Handler

func (*Handler) IndexFile

func (u *Handler) IndexFile() http.Handler

func (*Handler) IndexFileOnNotFound

func (u *Handler) IndexFileOnNotFound() http.Handler

func (*Handler) ServeAsset

func (u *Handler) ServeAsset() http.Handler

func (*Handler) ServeFaviconDashboard

func (u *Handler) ServeFaviconDashboard() http.Handler

type Options

type Options struct {
	// The location on disk of the UI files
	Path StringSetting
	// The HTTP URL of the index file to download
	Index StringSetting
	// Whether or not to run the UI offline, should return true/false/dynamic
	Offline StringSetting
	// Whether or not is it release, if true UI will run offline if set to dynamic
	ReleaseSetting BoolSetting
}

type StringSetting

type StringSetting func() string

Jump to

Keyboard shortcuts

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