Propagate mutation meta to default onError handler (from defaultOptions.mutations)
#8964
-
|
In global error handler (from Same applies to useMutation |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
|
the 4th argument isn’t The defaultOptions are observer options - the same ones you pass to
It’s probably best to do this in the global error handler. |
Beta Was this translation helpful? Give feedback.
the 4th argument isn’t
meta, it’s the mutation instance itself, which has a.metafield.The defaultOptions are observer options - the same ones you pass to
useMutation, and there, we also don’t pass themutationitself.It’s probably best to do this in the global error handler.