-
-
Notifications
You must be signed in to change notification settings - Fork 126
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
feat: make @asyncapi/react-component compatible with vs-asyncapi-preview #1078
Conversation
@catosaurusrex2003 Did you check to ensure it doesn't break the web-component? |
Quality Gate passedIssues Measures |
@AceTheCreator Thanks for pointing that out! I missed that check. I'll review it and get back to you shortly. |
@AceTheCreator (The title is not showing though) <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
</head>
<body>
<!-- Load the webcomponents polyfill if targeting older browsers -->
<script src="https://unpkg.com/@webcomponents/[email protected]/webcomponents-bundle.js"></script>
<script
type="module"
src="./node_modules/@asyncapi/web-component/lib/asyncapi-web-component.js"
defer
></script>
<asyncapi-component
schemaUrl="./asyncapi.yml"
config='{"show": {"info": false}}'
schemaFetchOptions='{"method":"GET","mode":"cors"}'
cssImportPath="./node_modules/@asyncapi/react-component/styles/default.min.css"
>
</asyncapi-component>
</body>
</html>
I also checked using it in nextjs should i test in angular, vue. |
@catosaurusrex2003 I think it's cuz you set info to false in the config
|
yes that seems to be the reason |
@AceTheCreator am i missing something in scope of this library. Like somewhere this library is used and my changes might break it. |
Exactly what i thought, currently working on a possible fix, i'll ping. |
I’d like to discard this PR as I realize I've made the solution more complicated than necessary. The simpler solution can be found in PR #1082. I should have taken more time to think through my approach before coding. @AceTheCreator |
Description
I merged
library/src/containers/AsyncApi/AsyncApi.tsx
andlibrary/src/containers/AsyncApi/Standalone.tsx
functionality intolibrary/src/containers/AsyncApi/Standalone.tsx
This pr will not cause any change/improvement in the working of
playground
or@asyncapi/react-component
.It wil improve
vs-asyncapi-preview
and will make the error to render as expected.Before:
After:
Related issue(s)
solves the issue #1077
and
asyncapi/vs-asyncapi-preview#200