feat: update swagger embedded files (#66)

This commit is contained in:
Eason Lin
2019-07-05 15:56:58 +08:00
committed by GitHub
parent 2d58c08c49
commit 08f491371f
3 changed files with 12 additions and 15 deletions
+2 -2
View File
@@ -2,8 +2,8 @@ package main
import (
"github.com/gin-gonic/gin"
"github.com/swaggo/files"
"github.com/swaggo/gin-swagger"
"github.com/swaggo/gin-swagger/swaggerFiles"
_ "github.com/swaggo/gin-swagger/example/basic/docs"
)
@@ -25,7 +25,7 @@ import (
func main() {
r := gin.New()
url := ginSwagger.URL("http://localhost:8080/swagger/doc.json") //The url pointing to API definition
url := ginSwagger.URL("http://localhost:8080/swagger/doc.json") // The url pointing to API definition
r.GET("/swagger/*any", ginSwagger.WrapHandler(swaggerFiles.Handler, url))
r.Run()