fawwaz
fawwaz16mo ago

Cannot find module error when deploying to Vercel

I'm seeing the below error when deploying to Vercel. According the docs we should run npm run build before first, but seems that it tries to access the _generated folder which is not part of the source. You can also find a picture of the project configuration on Vercel.
Using Convex with Vercel | Convex Developer Hub
Host your frontend on Vercel and your backend on Convex.
No description
No description
2 Replies
ballingt
ballingt16mo ago
@fawwaz we suggest committing the _generated directory to version control to avoid this. But you could add a codegen step to the beginning of your build command instead.
fawwaz
fawwazOP16mo ago
thanks million @ballingt , the codegen step fixed the issue

Did you find this page helpful?