Server actions are run but only return undefined on the client
I have a server action that I call in my useEffect, and I can verify that on my server the action gets called but the response on the client is always undefined. I've tried a bare minimum example where I only return a promise that resolves to a string but even that returns undefined.
Opened an issue on nextjs issues for this https://github.com/vercel/next.js/issues/69022. The undefined response is definitely a critical bug and I hope someone can touch upon this
I have a server action that I call in my useEffect, and I can verify that on my server the action gets called but the response on the client is always undefined. I've tried a bare minimum example where I only return a promise that resolves to a string but even that returns undefined.
I'm not having that issue when dealing with server actions. Can you show an example?
👋 We've updated this repo to have a more simplified example + a new guide:
- https://github.com/vercel/platforms/pull/451
- https://vercel.com/guides/nextjs-multi-tenant-application