From c9aca8c7cc3646afd3a126f0874cdb98920768c2 Mon Sep 17 00:00:00 2001 From: Azzyxec Date: Tue, 31 Dec 2024 12:51:47 +0530 Subject: [PATCH] Update server-functions.md In the section "Importing Server Functions from Client Components" updated "createNoteAction" to "createNote" to match the function name in the example --- src/content/reference/rsc/server-functions.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/content/reference/rsc/server-functions.md b/src/content/reference/rsc/server-functions.md index 74aab615c22..b079e322e69 100644 --- a/src/content/reference/rsc/server-functions.md +++ b/src/content/reference/rsc/server-functions.md @@ -82,7 +82,7 @@ export async function createNote() { ``` -When the bundler builds the `EmptyNote` Client Component, it will create a reference to the `createNoteAction` function in the bundle. When the `button` is clicked, React will send a request to the server to execute the `createNoteAction` function using the reference provided: +When the bundler builds the `EmptyNote` Client Component, it will create a reference to the `createNote` function in the bundle. When the `button` is clicked, React will send a request to the server to execute the `createNote` function using the reference provided: ```js [[1, 2, "createNote"], [1, 5, "createNote"], [1, 7, "createNote"]] "use client"; @@ -90,7 +90,7 @@ import {createNote} from './actions'; function EmptyNote() { console.log(createNote); - // {$$typeof: Symbol.for("react.server.reference"), $$id: 'createNoteAction'} + // {$$typeof: Symbol.for("react.server.reference"), $$id: 'createNote'}