first commit

This commit is contained in:
ngn
2023-12-09 19:25:38 +03:00
commit 30574d4aa2
19 changed files with 886 additions and 0 deletions

18
routes/index.go Normal file
View File

@ -0,0 +1,18 @@
package routes
import (
"github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/log"
)
func IndexRoute(c *fiber.Ctx) error{
content, err := GetContent("content", "readme")
if err != nil {
log.Error(err)
return c.Status(505).SendString("Server error")
}
return c.Render("index", fiber.Map{
"readme": content,
})
}