app

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2020 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthHandler

func AuthHandler(h http.Handler) http.Handler

func LoggedInOrAPITokenAuthHandler

func LoggedInOrAPITokenAuthHandler(h http.Handler) http.Handler

func LoggingHandler

func LoggingHandler(h http.Handler) http.Handler

func SetLoggedInHandler

func SetLoggedInHandler(h http.Handler) http.Handler

func SetPinnedTagsHandler

func SetPinnedTagsHandler(h http.Handler) http.Handler

func SetSettingsHandler

func SetSettingsHandler(h http.Handler) http.Handler

Types

type Sufr

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

Sufr is the main application struct. It also implements http.Handler so it can be passed directly into ListenAndServe

func New

func New(cfg *config.Config) *Sufr

New created a new pointer to Sufr

func (*Sufr) PinTagHandler

func (a *Sufr) PinTagHandler(w http.ResponseWriter, r *http.Request) error

func (Sufr) ServeHTTP

func (s Sufr) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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