update mod and main.go with html

This commit is contained in:
2021-07-03 21:26:55 +01:00
parent 8369af097c
commit 19ea728bc2
3 changed files with 32 additions and 1 deletions
+3 -1
View File
@@ -61,8 +61,10 @@ func main() {
}
return c.JSON(testitems)
})
app.Get("/", func(c *fiber.Ctx) error {
return c.SendString("Hello, World 👋!")
return c.SendString("<!DOCTYPE html><html><head><meta charset=\"utf-8\"><title>Mongo Test</title></head><body><h1>Hello, World 👋!\n</h1><p><a href=\"/atest\">atest records</a></p></body></html>")
})
log.Fatal(app.Listen(":3000"))