aboutsummaryrefslogtreecommitdiff
path: root/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'controllers')
-rw-r--r--controllers/home.go17
1 files changed, 17 insertions, 0 deletions
diff --git a/controllers/home.go b/controllers/home.go
new file mode 100644
index 0000000..1b513c8
--- /dev/null
+++ b/controllers/home.go
@@ -0,0 +1,17 @@
+package controllers
+
+import (
+ "imageboard/utils/shortcuts"
+
+ "github.com/gofiber/fiber/v2"
+)
+
+func HomeController(ctx *fiber.Ctx) error {
+ ctx.Locals("Title", "Home Page")
+ customdata := struct {
+ Custommessage string
+ }{
+ Custommessage: "Welcome to the Imageboard!",
+ }
+ return shortcuts.Render(ctx, "home", customdata)
+}