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

fix: $ref not being rendered correctly #240

Merged
merged 1 commit into from
Oct 16, 2024

Conversation

aditygrg2
Copy link
Contributor

Description
Fixes rendering of $ref references in AsyncAPI documents. After extensive debugging and investigation, I identified that the issue stemmed from how the schema was being injected into the AsyncAPI component.

During the testing phase, AsyncAPI documents containing $ref references were not rendering correctly in the VS Code extension, but were working well in our web envs (react-component and studio)

The main issue was the ordering of the definitions i.e, if the definition of operations is done at the last, the component will render properly. Better approach here was to directly first read the file and directly use it in the AsyncApiStandalone.render function instead of fetching it via URI.

Related issue(s)
Fixes #204 and closes asyncapi/asyncapi-react#913

Testing Screenshots:
Screenshot 2024-10-15 at 02 37 27

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome to AsyncAPI. Thanks a lot for creating your first pull request. Please check out our contributors guide useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

Copy link

@ivangsa
Copy link
Collaborator

ivangsa commented Oct 15, 2024

/rtm

@ivangsa
Copy link
Collaborator

ivangsa commented Oct 16, 2024

/rtm

@ivangsa
Copy link
Collaborator

ivangsa commented Oct 16, 2024

/rtm

@asyncapi-bot asyncapi-bot merged commit 8b1ffe8 into asyncapi:master Oct 16, 2024
21 checks passed
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.6.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants