In routers/legacy/route, we have the function:
func NewRouter(doc *openapi3.T) (routers.Router, error)
Which calls:
doc.Validate(context.Background())
As doc.Validate accepts validation options (signature: func (doc *T) Validate(ctx context.Context, opts ...ValidationOption) error) I would like to modify the NewRouter function (or add a new one named NewRouterWithValidationOptions), allowing to provide validation option:
func NewRouter(doc *openapi3.T, opts ...ValidationOption) (routers.Router, error)
If this is fine for you, I can create a pull request for it.
In routers/legacy/route, we have the function:
Which calls:
As
doc.Validateaccepts validation options (signature:func (doc *T) Validate(ctx context.Context, opts ...ValidationOption) error) I would like to modify theNewRouterfunction (or add a new one namedNewRouterWithValidationOptions), allowing to provide validation option:If this is fine for you, I can create a pull request for it.