fiberfx

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func App

func App(appName string, displayInfo bool, routes RoutesFx) fx.Option

func GetFiberApp

func GetFiberApp(appName string) string

func RunApp

func RunApp(addr, appName string, shutdownTimeout time.Duration) fx.Option

Types

type OptionsFunc

type OptionsFunc func(*options)

func WithPrefix

func WithPrefix(prefix string) OptionsFunc

func WithRouterCallback

func WithRouterCallback(cb func(fiber.Router)) OptionsFunc

func WithRoutes

func WithRoutes(routes ...RouteFx) OptionsFunc

type RouteFx

type RouteFx func(appName, prefix string) fx.Option

func Delete

func Delete(path string, handler any) RouteFx

func DeleteWithRouterCallback

func DeleteWithRouterCallback(path string, cb func(fiber.Router), handler any) RouteFx

func Get

func Get(path string, handler any) RouteFx

func GetWithRouterCallback

func GetWithRouterCallback(path string, cb func(fiber.Router), handler any) RouteFx

func Patch

func Patch(path string, handler any) RouteFx

func PatchWithRouterCallback

func PatchWithRouterCallback(path string, cb func(fiber.Router), handler any) RouteFx

func Post

func Post(path string, handler any) RouteFx

func PostWithRouterCallback

func PostWithRouterCallback(path string, cb func(fiber.Router), handler any) RouteFx

func Put

func Put(path string, handler any) RouteFx

func PutWithRouterCallback

func PutWithRouterCallback(path string, cb func(fiber.Router), handler any) RouteFx

func Route

func Route(method, path string, handler any) RouteFx

func RouteWithRouterCallback

func RouteWithRouterCallback(method, path string, cb func(fiber.Router), handler any) RouteFx

type RoutesFx

type RoutesFx func(appName string) fx.Option

func Routes

func Routes(opts ...OptionsFunc) RoutesFx

Jump to

Keyboard shortcuts

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