middleware

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2025 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Auth

func Auth(c Conf) func(http.Handler) http.Handler

Auth determines whether a user is logged in or not for a request.

func Build

func Build(sha, tag string) func(http.Handler) http.Handler

func Cache

func Cache(cache *cache.Cache) func(http.Handler) http.Handler

func Config

func Config(config Conf) func(http.Handler) http.Handler

func Etag

func Etag(c Conf) func(http.Handler) http.Handler

func GetPersistedEtag

func GetPersistedEtag(key string) string

func Logger

func Logger(c Conf) func(http.Handler) http.Handler

log all URLs with request duration

func Params

func Params(c Conf) func(http.Handler) http.Handler

func PersistEtag

func PersistEtag(key, etag string)

func RemoveEtags

func RemoveEtags()

Types

type CacheKey

type CacheKey = types.CacheKey

type Conf

type Conf = types.Conf

type ConfigKey

type ConfigKey = types.ConfigKey

type FilterParams

type FilterParams = types.FilterParams

type ParamsKey

type ParamsKey = types.ParamsKey

type ResponseFilter

type ResponseFilter = types.ResponseFilter

type UserKey

type UserKey = types.UserKey

Jump to

Keyboard shortcuts

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