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

💄 Switch from Swagger UI to RapiDoc #1081

Merged
merged 3 commits into from
Sep 27, 2021
Merged

💄 Switch from Swagger UI to RapiDoc #1081

merged 3 commits into from
Sep 27, 2021

Conversation

afranke
Copy link
Contributor

@afranke afranke commented Sep 24, 2021

For a more modern interface to explore the API.

@afranke afranke marked this pull request as draft September 24, 2021 14:03
@afranke afranke force-pushed the rapidoc branch 5 times, most recently from baf6cc0 to e6857ed Compare September 24, 2021 15:44
Signed-off-by: Alexandre Franke <alexandre.franke@matrix.org>
@afranke afranke marked this pull request as ready for review September 24, 2021 16:11
@afranke
Copy link
Contributor Author

afranke commented Sep 24, 2021

Before

image

After

image

Notes

  • RapiDoc supports custom API servers, but getting an entry like the one we had before requires adding metadata to the spec definition. I’ll take care of that in a separate PR to the matrix-doc repository. I don’t consider this a blocker.
  • I didn’t style RapiDoc with the website header/navbar on purpose because quite frankly it’s ugly in this context, gets in the way, and I doubt someone really needs to jump from the playground directly to the blog… The [matrix] logo in the top left corner is a link back to the Develop section, where visitors can then find the navbar again.
  • RapiDoc supports both Swagger 2.0 and OpenAPI 3.x.x, so we won’t have to change anything when we make that move eventually.

Copy link
Member

@anoadragon453 anoadragon453 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor clarifying points, but otherwise looks good to me.

Design may want to modify the colour scheme at some point, but from your screenshot I think it looks pretty slick for a first pass (though I have no idea about accessibility for instance).

scripts/swagger-ui.patch Show resolved Hide resolved
scripts/update_docs.sh Show resolved Hide resolved
rapidoc/index.html Show resolved Hide resolved
Alexandre Franke added 2 commits September 27, 2021 09:46
Signed-off-by: Alexandre Franke <alexandre.franke@matrix.org>
Signed-off-by: Alexandre Franke <alexandre.franke@matrix.org>
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 this pull request may close these issues.

2 participants