Adding the wiki route and better styling

This commit is contained in:
ngn
2024-01-06 23:20:58 +03:00
parent 6477240dd4
commit 7f61a0cd58
15 changed files with 299 additions and 161 deletions

View File

@ -1,18 +1,19 @@
package routes
import (
"git.matterlinux.xyz/Matterlinux/website/lib"
"github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/log"
)
func IndexRoute(c *fiber.Ctx) error{
content, err := GetContent("content", "index")
con, err := lib.GetContent("", "index")
if err != nil {
log.Error(err)
return RenderError(c, 500)
log.Error("GetContent -> ", err)
return lib.RenderError(c, 500)
}
return c.Render("index", fiber.Map{
"readme": content,
"readme": con,
})
}