import "github.com/yuta-yoshinaga/go_trumpcards/internal/infrastructure/cors"func Middleware(allowedOrigins map[string]bool, next http.Handler) http.HandlerMiddleware returns an http.Handler that applies CORS headers for the given set of allowed origins. Only POST requests with Content-Type are permitted. Preflight OPTIONS requests receive the appropriate headers and a 204 response.
func ParseOrigins(csv string) map[string]boolParseOrigins parses a comma-separated list of origins into a map.
Generated by gomarkdoc