BETTER-AUTH. UI
Mutations

updateUserOptions

Update the current user's profile fields.

Usage

import { updateUserOptions } from "@better-auth-ui/solid"
import { createMutation } from "@tanstack/solid-query"

const updateUser = createMutation(() => updateUserOptions(authClient))

updateUser.mutate({ name: "Alice" })

Cache

Invalidate authQueryKeys.session after a successful update so cached user data refreshes.

Params

Prop

Type

Last updated on

On this page