You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently I am trying to initiate a project with swaggo then encountered this error Uncaught Invariant Violation: Minified React error #37
I couldn't provide complete steps to reproduce this error because it's a new project that generated from a template automatically. But the main steps are:
First go get github.com/swaggo/swag, then swag init to generate /docs/swagger directory with docs.go, swagger.json and swagger.yaml files.
Versions:
swaggo/swag v1.8.1
swaggo/http-swagger v1.2.7
Describe the bug:
Recently I am trying to initiate a project with swaggo then encountered this error
Uncaught Invariant Violation: Minified React error #37
I couldn't provide complete steps to reproduce this error because it's a new project that generated from a template automatically. But the main steps are:
First go get github.com/swaggo/swag, then swag init to generate /docs/swagger directory with docs.go, swagger.json and swagger.yaml files.
Then go to http://localhost:_port_/docs/index.html to see the blank page.
So there's actually no too much customization.
Solution
After searching a bit I found a similar issue in swagger-ui: swagger-api/swagger-ui#5608.
I've successfully fixed this error locally by changing the default
dom_id
here to#swagger-ui
:http-swagger/swagger.go
Line 117 in 285f7b0
e.g.
Please let me know if any concerns, it will not block my progress since I'll switch to edit the swagger doc manually, so not urgent here. 😄
The text was updated successfully, but these errors were encountered: