Files
nl_cms-api/internal/middleware/cors.go

11 lines
169 B
Go
Raw Normal View History

2025-07-29 12:45:07 +08:00
package middleware
import (
"github.com/gogf/gf/v2/net/ghttp"
)
// CORS 跨域中间件
func CORS(r *ghttp.Request) {
r.Response.CORSDefault()
r.Middleware.Next()
}