Documentation
¶
Index ¶
- func CORSMiddleware(ctx context.Context, acceptedOrigins []string) gin.HandlerFunc
- func InitServer(ctx context.Context, defineRoutes DefineRoutesFunc, acceptedOrigins []string) (string, *gin.Engine)
- func StartServer(ctx context.Context, router *gin.Engine, address string) func()
- type DefineRoutesFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CORSMiddleware ¶ added in v0.2.0
func CORSMiddleware(ctx context.Context, acceptedOrigins []string) gin.HandlerFunc
func InitServer ¶
func InitServer(ctx context.Context, defineRoutes DefineRoutesFunc, acceptedOrigins []string) (string, *gin.Engine)
InitServer initializes the server and returns the server address and router.
Types ¶
Click to show internal directories.
Click to hide internal directories.