feat: integrated swagger

This commit is contained in:
2025-06-18 03:14:51 +03:00
parent 9e8dd9bf2f
commit ec40c86e4a
8 changed files with 230 additions and 9 deletions

View File

@@ -6,6 +6,10 @@ import (
"easywish/config"
"easywish/internal/logger"
"easywish/internal/routes"
docs "easywish/docs"
swaggerfiles "github.com/swaggo/files"
ginSwagger "github.com/swaggo/gin-swagger"
)
func main() {
@@ -18,6 +22,10 @@ func main() {
r := gin.Default()
r = routes.SetupRoutes(r)
docs.SwaggerInfo.BasePath = "/api/"
r.GET("/swagger/*any", ginSwagger.WrapHandler(swaggerfiles.Handler))
r.Run(":8080")
}