fiber

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 12, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ETag = configRoot + ".ETag"

	GETOnly = configRoot + ".GETOnly"

	PluginsRoot = root + ".plugins"
)

Variables

This section is empty.

Functions

func JSON

func JSON(c *fiber.Ctx, code int, i interface{}, err error) error

func JSONError

func JSONError(c *fiber.Ctx, err error) error

Types

type Options

type Options struct {
	Port   int
	Config *fiber.Config
}

func NewOptions

func NewOptions() (*Options, error)

func NewOptionsWithPath

func NewOptionsWithPath(path string) (opts *Options, err error)

type Plugin

type Plugin func(context.Context, *fiber.App) error

type Server

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

func NewServer

func NewServer(ctx context.Context, plugins ...Plugin) *Server

func NewServerWithOptions

func NewServerWithOptions(ctx context.Context, options *Options, plugins ...Plugin) *Server

func (*Server) App

func (s *Server) App() *fiber.App

func (*Server) Serve

func (s *Server) Serve(ctx context.Context)

Jump to

Keyboard shortcuts

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