mirror of
https://github.com/kataras/iris.git
synced 2026-01-08 20:41:57 +00:00
more route info improvements
Former-commit-id: ccbe95de0badb1bf448fcc443cecda60772716dc
This commit is contained in:
@@ -35,6 +35,8 @@ func configureAPI(api *iris.APIContainer) {
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
app.Logger().SetLevel("debug")
|
||||
|
||||
app.ConfigureContainer(configureAPI)
|
||||
app.Listen(":8080")
|
||||
}
|
||||
|
||||
@@ -14,6 +14,8 @@ var cacheHandler = cache.Handler(10 * time.Second)
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
app.Logger().SetLevel("debug")
|
||||
|
||||
mvc.Configure(app, configure)
|
||||
|
||||
// http://localhost:8080
|
||||
|
||||
@@ -103,7 +103,7 @@ func main() {
|
||||
usersRoutes.Delete("/{id:uint64}", func(ctx iris.Context) {
|
||||
id, _ := ctx.Params().GetUint64("id")
|
||||
ctx.Writef("delete user by id: %d", id)
|
||||
}).SetDescription("deletes a user")
|
||||
}).Describe("deletes a user")
|
||||
|
||||
// Subdomains, depends on the host, you have to edit the hosts or nginx/caddy's configuration if you use them.
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user