Functions between server and client
Unanswered
Rough harvester ant posted this in #help-forum
Rough harvester antOP
If I reference a function in a file marked as 'use server' in a client component, does calling it make a http request to the server calling it?
2 Replies
Context:
Source:
https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations#behavior
Behind the scenes, actions use the POST method, and only this HTTP method can invoke them.
Source:
https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations#behavior