sanic-org / sanic-openapi

Easily document your Sanic API with a UI
https://sanic-openapi.readthedocs.io/
MIT License
505 stars 108 forks source link

[Feature Request] Add configuration to turn off swagger in production environment #186

Closed wei-hai closed 4 years ago

wei-hai commented 4 years ago

Add some flag in the configuration to turn off the swagger page or show no URI.

denisovkiv commented 4 years ago

Hello! What about next workaround:

if settings.DEBUG:
    app.blueprint(swagger_blueprint)

Don't think this feature is relevant

ahopkins commented 4 years ago

I would agree. Thank you for the thoughts but this doesn't seem like a feature that needs internal support.