Documentation ¶
Overview ¶
Package gobase is a web framework with basic settings and structure, wrapping labstack/echo.
Example:
package main import ( "net/http" "github.com/labstack/echo/v4" "github.com/cancue/gobase" "github.com/cancue/gobase/config" "github.com/cancue/gobase/router" ) func main() { gb := gobase.Server{ Config: &config.Config{ Stage: "local", YAML: map[string]interface{}{ "name": "gobase-demo", "server": map[string]interface{}{ "port": 8888, "timeout": map[string]interface{}{ "read": 600, "write": 600, }, }, }, }, Router: func(s router.Server) { s.GET("/", func(ctx echo.Context) error { return ctx.String(http.StatusOK, "Hello, World!") }) }, } gb.Start() }
You may want to check out https://github.com/cancue/gobase-demo
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.