TanStack · Function
mutationOptions
mutationOptions creates typed mutation settings for reuse. In Vue, use its getter form when settings read reactive state, and add mutationKey when another API must find the mutation by key.
Last updated
Syntax
function mutationOptions<TData = unknown, TError = Error, TVariables = void, TOnMutateResult = unknown>(options: MutationOptions<TData, TError, TVariables, TOnMutateResult>): MutationOptions<TData, TError, TVariables, TOnMutateResult>In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
useMutationuseMutationStateMutationOptions