Nextjs server actions method not allowed
Answered
"use php" posted this in #help-forum
I'm getting method not allowed error when I'm using server actions.
I'm only getting in production & when I run the server locally.
I'm only getting in production & when I run the server locally.
Answered by "use php"
So, I basically need to set runtime of layout.tsx as edge to fix.
4 Replies
I'm Trying to execute a server action from client side and I'm getting this error. It works fine in development, but in production & local build I get this error Method not allowed
I'm still trying some solutions
@"use php" I'm getting method not allowed error when I'm using server actions.
I'm only getting in production & when I run the server locally.
This is the error message I get on console also, 405 method not allowed
So, I basically need to set runtime of layout.tsx as edge to fix.
Answer