-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Using UUID in API routes gives Cannot read properties of undefined (reading 'v4')
#8118
Comments
I am seeing the same error in my project. The |
I'm seeing this in my
Switching to |
this was working for us in hooks.server.ts in "@sveltejs/kit": "1.0.0-next.570", upgrading to 1.0.0 I see the same issue. ... actually it looks like it might be a vite issue, i upgraded only it from previous working state and the issue occurs, from 3.2.4 to 4.0.1. I went ahead and filed an issue on the vite repo using OP's original details. |
this seems to be an issue in vite, tracked at vitejs/vite#11385 |
This is fixed in vite 4.0.3 |
Describe the bug
I try to use
uuid.v4()
in an API route but Sveltekit is giving me this error. Code:Reproduction
https://github.com/ThangHuuVu/sveltekit-uuid-reproduction
https://sveltekit-repro-uuid-thvu.vercel.app/
Logs
Severity
annoyance
Additional Information
No response
The text was updated successfully, but these errors were encountered: