productcatalog

package
v0.0.0-...-990eb5e Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidSlug = errors.New("invalid slug value")

Functions

func RegisterRoutes

func RegisterRoutes(h *Handler, mux *http.ServeMux)

Types

type BindValidator

type BindValidator interface {
	Binder
	Validator
}

type Binder

type Binder interface {
	Bind(r *http.Request) error
}

type Handler

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

func NewHandler

func NewHandler(
	userSvc anor.UserService,
	productSvc anor.ProductService,
	categorySvc anor.CategoryService,
	searcher search.Searcher,
	render *html.Render,
	logger *slog.Logger,
	session *scs.SessionManager,
) *Handler

func (*Handler) NotFound

func (h *Handler) NotFound(next http.HandlerFunc) http.HandlerFunc

type Validator

type Validator interface {
	Validate() error
}

Jump to

Keyboard shortcuts

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