Skip to content
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

Add flexibility to utoipa-swagger-ui build process #844

Closed
oscar6echo opened this issue Jan 13, 2024 · 2 comments · Fixed by #845
Closed

Add flexibility to utoipa-swagger-ui build process #844

oscar6echo opened this issue Jan 13, 2024 · 2 comments · Fixed by #845

Comments

@oscar6echo
Copy link
Contributor

First I would like to stress how much I appreciate this lib and the effort put in it 🙏

It is great and I have been experimenting and adapting it to a corporate context.
Doing so I found that the build process could be made more flexible in order to:

  • allow other versions of swagger-ui
  • allow overwrite of files in swagger-ui/dist

While not everybody needs that sort of flex, it would certainly help some users, like me, while keeping the defaults unchanged.
To propose a solution, I'll make a PR.

@oscar6echo
Copy link
Contributor Author

Here is the PR: #845

Happy to discuss it.

Pls note that in the meantime it is already used in a corp environment 👍

@juhaku
Copy link
Owner

juhaku commented Jan 23, 2024

This good addition, I have actually been wondering that something like this could be good addition but just haven't gone the extra mile to implement it.

juhaku added a commit that referenced this issue Jan 23, 2024
This PR changes the fact that Swagger UI was vendored dependency. While this 
makes sure that everyone has a working Swagger UI, it is rather rigid and slow
update cycle for users. This commit updates the Swagger UI to the latest version by
default (5.11.0) and removes the vendored Swagger UI completely. The Swagger UI 
will now be downloaded upon `utoipa-swagger-ui` build while allowing users 
optionally define a version of choice and override files in the Swagger UI. Swagger UI 
can also be defined with a custom path that contains the pre downloaded Swagger UI.

Resolves #844 
---------

Co-authored-by: Juha Kukkonen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants