From 71da0f4de17a790c70b74ffe44f2c11976f4c88b Mon Sep 17 00:00:00 2001 From: chaeyeonhee Date: Wed, 27 Nov 2024 20:34:32 +0900 Subject: [PATCH] docs(server-actions): add missing formData type --- .../02-data-fetching/03-server-actions-and-mutations.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/01-app/02-building-your-application/02-data-fetching/03-server-actions-and-mutations.mdx b/docs/01-app/02-building-your-application/02-data-fetching/03-server-actions-and-mutations.mdx index 0082e35548f3c..4b2fce0dfbb62 100644 --- a/docs/01-app/02-building-your-application/02-data-fetching/03-server-actions-and-mutations.mdx +++ b/docs/01-app/02-building-your-application/02-data-fetching/03-server-actions-and-mutations.mdx @@ -510,7 +510,7 @@ export function Thread({ messages }: { messages: Message[] }) { string >(messages, (state, newMessage) => [...state, { message: newMessage }]) - const formAction = async (formData) => { + const formAction = async (formData: FormData) => { const message = formData.get('message') as string addOptimisticMessage(message) await send(message)