miko

package module
v0.0.0-...-b899af2 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2023 License: MIT Imports: 5 Imported by: 0

README

miko

Small web framework with templates

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnsupportedMediaType = errors.New("UnsupportedMediaType")
)

Functions

This section is empty.

Types

type App

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

func NewApp

func NewApp() *App

func (*App) Get

func (app *App) Get(pattern string, h Handler)

func (*App) Listen

func (app *App) Listen(addr string) error

func (*App) Post

func (app *App) Post(pattern string, h Handler)

type Context

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

func (*Context) BindJson

func (c *Context) BindJson(v any) error

func (*Context) FormValue

func (c *Context) FormValue(name string) string

func (*Context) Json

func (c *Context) Json(data any) error

func (*Context) QueryString

func (c *Context) QueryString(name string) string

func (*Context) RouteParam

func (c *Context) RouteParam(name string) string

func (*Context) StatusJson

func (c *Context) StatusJson(data any, statusCode int) error

func (*Context) String

func (c *Context) String(text string) error

type Handler

type Handler func(*Context) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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