-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Error deploying to Vercel #7424
Comments
For p5.js 1.x, using the library with ES modules is not supported and not guaranteed to work, it is recommended to use regular script tag without |
Then sketch.js and secondscketch.js are recommended to use type="module" or not...A i import classes and functions from other files i think is better to call them modules. Also without type="module" do you recommend using defer or better await in script "calling": One last question...whats the difference between p5.min and p5.js and p5.sound and p5.min.sound.... Thanks |
It is not recommended to use The The difference between the |
Why you close if its not solved |
@ejgutierrez74 There hasn't been a reply in a while so I would have to assume the issue has been resolved at some point, also the solution has already been provided in that |
Yes but if you make this in local it works fine. if you dont put type module in p5 it doesnt work in vite local. So you have to add it and it works fine in local. The problem i dont think its async or defer is that some structure that works fine in local in vite, its not "well" deployed to vercel |
You don't have to use type module with vite, only if you are using ES modules, which doesn't work with p5.js at the moment. It may be possible to use it with instance mode if you really have to use ES modules but it is not tested by us to work. |
I tried several times, the same code without type module doesnt work in Vite, the same code with type module works... |
Topic
Not showing p5,js sketches as Vercel gives an not defined error, in Vite works fine.
Also would like to go to myrpoject/docs and show the jsdoc documentation.
Load my project, and sketches are not shown…
[vercel.com] (https://vercel.com/login?next=%2Fejgutierrez74s-projects%2Fpacman2024windows)
[Dashboard] (https://vercel.com/login?next=%2Fejgutierrez74s-projects%2Fpacman2024windows)
With vite works fine, but in vercel i got an error when i deploy to Vercel
As vite in local i want to access my index.html showing some p5.js sketches, and then if i go to myproject/docs show de index of documentation.
Structure of my project;
This is the caling of scripts in index.html in root project:
I really need help im a teacher in vocational education, and with my students we are stuck.
Thanks
The text was updated successfully, but these errors were encountered: