plug

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compress

func Compress(h http.Handler) http.Handler

func Static

func Static(h http.Handler) http.Handler

Types

type Handler

type Handler func(db *db.Config, w http.ResponseWriter, r *http.Request)

func AcceptJSON

func AcceptJSON(h Handler) Handler

func CSRF

func CSRF(h Handler) Handler

func Captcha

func Captcha(h Handler) Handler

func FetchFlash

func FetchFlash(h Handler) Handler

func FetchSession

func FetchSession(h Handler) Handler

func RequireAccount

func RequireAccount(h Handler) Handler

func RequireLogout

func RequireLogout(h Handler) Handler

func SecureHeaders

func SecureHeaders(h Handler) Handler

func SessionTimeout

func SessionTimeout(h Handler) Handler

func VerifyCSRF

func VerifyCSRF(h Handler) Handler

type Middleware

type Middleware func(h Handler) Handler

type Pipeline

type Pipeline []Middleware

func Browser

func Browser() Pipeline

func InternalStats

func InternalStats() Pipeline

func (Pipeline) Then

func (p Pipeline) Then(h Handler) func(db *db.Config, w http.ResponseWriter, r *http.Request)

func (Pipeline) With

func (p Pipeline) With(m ...Middleware) Pipeline

Jump to

Keyboard shortcuts

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