-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Loading multiple swagger files with ReDoc #187
Comments
In your demo code, can "swagger.yaml" be dynamically changed to specific specs? If I am following correctly, your swagger.yaml contains each of the apis in the demo. I'm looking to support upwards of 80 apis with ReDoc, so the loading time would suffer if it has to render all within one file. Please let me know if I am understanding your dynamic linking incorrectly! |
From my point of view, since redoc is juste a simple client side app, you can create a basic HTML homepage with some links to your differents api. Each API could be a link to a different "redoc" instance. |
@nemenemsrouge thanks, you're absolutely correct 👍
Probably you've mistaken something, our swagger.yaml contains spec of only ONE API with a lot of operations @katschre summing up so far you have two options:
I will create a few basic examples today so you can base your solution on |
Here is an example of hosting multiple specs on the same page: https://github.com/Rebilly/ReDoc/blob/master/demo/examples/multiple-apis/index.html |
Update, the multi-api example is now on the gh-pages branch: https://github.com/Rebilly/ReDoc/blob/gh-pages/examples/multiple-apis/index.html |
If it helps https://github.com/dbones/ink consider this a simple solution to this problem |
I have written a docker image for that problem. If you are interested, you can use it :) Feel free: https://hub.docker.com/r/volbrene/redoc |
@volbrene thank you for the docker image I like how you solved this issue, would you be open to putting the source code for this in Github so we could customize it for our use? |
I have now published the git in Github. https://github.com/volbrene/redoc |
Hello! I am looking for a solution or example for rendering multiple swagger spec files. Is there an existing/preferred solution for loading multiple swagger files, rather loading all APIs into a single yaml file (i.e. swagger.yaml in the demo code)?
The text was updated successfully, but these errors were encountered: