diff --git a/docs/start/framework/react/server-functions.md b/docs/start/framework/react/server-functions.md index c8c11e861b..6e0a0e7386 100644 --- a/docs/start/framework/react/server-functions.md +++ b/docs/start/framework/react/server-functions.md @@ -98,7 +98,7 @@ const UserSchema = z.object({ }) export const createUser = createServerFn({ method: 'POST' }) - .inputValidator((data) => UserSchema.parse(data)) + .inputValidator(UserSchema) .handler(async ({ data }) => { // data is fully typed and validated return `Created user: ${data.name}, age ${data.age}`