directory
0.0.4
Repository: https://github.com/cpchain/cpchain-golang-sdk.git
Documentation: pkg.go.dev

# Packages

Package cors is net/http handler to handle CORS related requests as defined by http://www.w3.org/TR/cors/ You can configure it by passing an option struct to cors.New: c := cors.New(cors.Options{ AllowedOrigins: []string{"foo.com"}, AllowedMethods: []string{"GET", "POST", "DELETE"}, AllowCredentials: true, }) Then insert the handler in the chain: handler = c.Handler(handler) See Options documentation for more options.
Package xhandler provides a bridge between http.Handler and net/context.