-
-
Notifications
You must be signed in to change notification settings - Fork 127
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
Not able to use this with Vite. How? #703
Comments
Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request. |
@fhareide Hi! Thanks for the issue! Are you using Vite + React or Vite + another render lib/framework? Maybe there's a problem. How exactly are you using component - normal React component, component without parser or standalone component? |
Vite + react. I have tried all combinations I could think of. It's not totally clear to me how to set it up with the different methods. |
@magicmatatjahu Any news on this one? |
Hey! Wanted to let you know that I also struggle with the same problem. First thought it is the framework problem, but then I can't even make it work with webpack etc. |
@magicmatatjahu I used the Uncaught ReferenceError: process is not defined
at node_modules/@apidevtools/json-schema-ref-parser/lib/util/url.js (url.js:3:29)
at __require2 (chunk-6FBSFQRG.js?v=f184a0b1:18:50)
at node_modules/@apidevtools/json-schema-ref-parser/lib/pointer.js (pointer.js:6:13)
at __require2 (chunk-6FBSFQRG.js?v=f184a0b1:18:50)
at node_modules/@apidevtools/json-schema-ref-parser/lib/ref.js (ref.js:5:17)
at __require2 (chunk-6FBSFQRG.js?v=f184a0b1:18:50)
at node_modules/@apidevtools/json-schema-ref-parser/lib/refs.js (refs.js:4:14)
at __require2 (chunk-6FBSFQRG.js?v=f184a0b1:18:50)
at node_modules/@apidevtools/json-schema-ref-parser/lib/index.js (index.js:4:15)
at __require2 (chunk-6FBSFQRG.js?v=f184a0b1:18:50) |
I am also facing the same issue. |
Any progress on this? Really want to migrate away from CRA. |
Also having this issue. CRA is no longer recommended by React so I imagine this will get more attention as time goes on.
To work around this part, I added to my
However now I'm getting the error:
Example code:
Any further investigation done into this problem? @magicmatatjahu |
i'm hitting this same issue and was able to workaround it with the following diff:
|
Encountering the same error. Any updates? Vite v4.3.9 |
Maybe all of you already has figured this out but you can use the standalone version of the component with vite.
|
@mr-nuno's answer is almost complete. This will display the asyncapi doc, but without any formatting. You need to go one step further to inject the CSS.
|
correct @dansiemens1, sorry about that :-) |
This issue has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation. There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
I'm trying to use this package in a Vite project but get "Uncaught ReferenceError: process is not defined".
I have not found out how to use a version that work with Vite. Any help is much appreciated. And maybe it should be added to documentation?
The text was updated successfully, but these errors were encountered: