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

gh-pages: view link and download link for latest JSON schemas #4034

Merged

Conversation

ralfhandl
Copy link
Contributor

@ralfhandl ralfhandl commented Aug 16, 2024

  • HTML wrappers for "schema" and "schema-base" for nice rendering of latest schema version
  • download links for all published schema versions

image

Preview: https://ralfhandl.github.io/OpenAPI-Specification/

Also work if site is deployed with non-empty base URL
mikekistler
mikekistler previously approved these changes Aug 20, 2024
Copy link
Contributor

@mikekistler mikekistler left a comment

Choose a reason for hiding this comment

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

Looks good. 👍

Strange highlighting in the "latest" files -- I'm taking that to be a GitHub anomaly.

@ralfhandl ralfhandl dismissed mikekistler’s stale review August 20, 2024 15:58

The merge-base changed after approval.

mikekistler
mikekistler previously approved these changes Aug 22, 2024
Copy link
Contributor

@mikekistler mikekistler left a comment

Choose a reason for hiding this comment

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

Reapproving.

@ralfhandl ralfhandl dismissed mikekistler’s stale review August 22, 2024 16:31

The merge-base changed after approval.

Copy link
Member

@handrews handrews left a comment

Choose a reason for hiding this comment

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

Can we instead create a "view" page that embeds the schema with highlighting? It's such an anti-pattern to use a suffix over HTTP and I do not want some people to start referencing the schema as a .json file when the correct URL is the one without it.

@handrews
Copy link
Member

@ralfhandl now I'm noticing that these are called "latest", but really we want people to take specific dated versions of the schema. It's not good to have your validation rules change under you without notice. Or am I misunderstanding what "latest" means here?

@ralfhandl
Copy link
Contributor Author

@handrews How about listing all schema versions for download, and only viewing the latest in an HTML wrapper:

image

Live preview:

handrews
handrews previously approved these changes Aug 29, 2024
Copy link
Member

@handrews handrews left a comment

Choose a reason for hiding this comment

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

This is an improvement over what we have!

@ralfhandl ralfhandl dismissed handrews’s stale review August 29, 2024 16:29

The merge-base changed after approval.

@lornajane lornajane removed the request for review from mikekistler August 29, 2024 16:32
@lornajane lornajane merged commit 08a99b0 into OAI:gh-pages Aug 29, 2024
@ralfhandl ralfhandl deleted the gh-pages-json-schema-view-or-download branch August 29, 2024 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
editorial Wording and stylistic issues Housekeeping
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants