-
-
Notifications
You must be signed in to change notification settings - Fork 199
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
Remove swagger-ui #672
Remove swagger-ui #672
Conversation
What is the rationale behind this change? |
We want to remove swagger-ui from fastify-swagger and create a new plugin fastify-swagger-ui which has the swagger-ui part. So based on that you can have e.g. a fastify-rapidoc impementation where you use fastify-swagger for swagger file generation and rapidoc as openapi viewer. |
Makes sense. Then probably we first should release fastify-swagger-ui before this lands? |
I am still missing 3 code branches for 100% test coverage. @kibertoad |
We need to document migration path to fastify-swagger-ui somewhere |
|
So! It seems that it is done code wise. Now regarding the documentation: How should it be done? I thought of:
Do you agree? Anything that I miss? Btw. code review is welcome. |
Could be |
I created the migration documentation. So please review it :) |
@mcollina PTAL |
So when we merge this and release, then we should do the follow up:
It is utmost important to release a new version of @fastify/swagger-ui. |
Using now import for top level await. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Rando here who was really confused trying to set this up: @fastify/swagger 8.0 is published but @fasitfy/swagger-ui is not. Any ETA? |
No problem, impeccable timing on my part! Thanks |
@gspetrou |
Thanks for working on this btw @Uzlopak. Never used the UI part in my APIs and it added an extra ~4MB to the build, which for some accounted for 20% of their size! |
Great feature, because as you, I was not using swagger-ui. Thx |
You'll need to define the routes yourself: https://github.com/fastify/fastify-swagger-ui/blob/master/lib/routes.js#L95-L115 |
Hi, I can use fastify-swagger with fastify-swagger-ui now, and I also can use RapicDoc to get the json. |
Please open a new detailed issue to be useful for others Spoiler: |
Checklist
npm run test
andnpm run benchmark
and the Code of conduct