mirror of
https://github.com/labstack/echo.git
synced 2025-07-05 00:58:47 +02:00
Middleware with options - 2
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
@ -31,6 +31,16 @@ func main() {
|
||||
return false
|
||||
}))
|
||||
|
||||
//-------
|
||||
// Slash
|
||||
//-------
|
||||
|
||||
e.Use(mw.StripTrailingSlash())
|
||||
|
||||
// or
|
||||
|
||||
// e.Use(mw.RedirectToSlash())
|
||||
|
||||
// Routes
|
||||
e.Get("/", hello)
|
||||
|
||||
|
Reference in New Issue
Block a user