Refactor handlers into separate packages and implement dependency injection.

IDK if this shit is good or even logical, but it works and I can wrap my head around it.
This commit is contained in:
2025-05-14 20:03:06 +03:30
parent 02461d0bb0
commit 943925c3e9
9 changed files with 76 additions and 52 deletions

View File

@@ -1,12 +1,11 @@
package internal
import (
"github.com/gin-gonic/gin"
"gorm.io/gorm"
// "github.com/gin-gonic/gin"
// "gorm.io/gorm"
)
type AppWebContext struct {
Db *gorm.DB
GinEngine *gin.Engine
}
// type AppWebContext struct {
// Db *gorm.DB
// GinEngine *gin.Engine
// }