server

package
v0.0.0-...-01e8a6e Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2021 License: MIT Imports: 23 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrHandler

func ErrHandler(err error) http.Handler

func New

func New() http.Handler

New makes a new server.

func Render

func Render(ctx context.Context, w io.Writer, images []string) error

Types

type Category

type Category struct {
	ID     string  `json:"id"`
	Name   string  `json:"name"`
	Images []Image `json:"images"`
}

type FileServer

type FileServer string

func (FileServer) ServeHTTP

func (f FileServer) ServeHTTP(w http.ResponseWriter, r *http.Request)

type Image

type Image struct {
	ID            string `json:"id"`
	Name          string `json:"name"`
	Href          string `json:"href"`
	ThumbnailHref string `json:"thumbnail_href"`
}

Jump to

Keyboard shortcuts

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