feat: modularize the code.

This commit is contained in:
CronyAkatsuki 2025-11-07 18:16:45 +01:00
parent 6f4757a1e9
commit a59c892087
7 changed files with 293 additions and 243 deletions

17
index.go Normal file
View file

@ -0,0 +1,17 @@
package main
import (
"github.com/labstack/echo/v4"
"net/http"
)
type IndexData struct {
Host string
}
func Index(c echo.Context) error {
data := IndexData{
Host: domain,
}
return c.Render(http.StatusOK, "index", data)
}