routes

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Route

type Route struct {
	Name   string
	Path   string
	Method string
	Data   any
	Body   types.Body
}

func ServerRoutes

func ServerRoutes(app core.App) []Route

type RouteGroup

type RouteGroup struct {
	Prefix string
	Routes []Route
}

func NewRouteGroup

func NewRouteGroup(prefix string) *RouteGroup

func (*RouteGroup) AddRoute

func (r *RouteGroup) AddRoute(name, path, method string, data any, body types.Body)

func (*RouteGroup) Register

func (r *RouteGroup) Register(handlers ...apis.Handler)

Jump to

Keyboard shortcuts

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