Deprecating useStateAction
means no more onSuccess/onError callbacks for stateful actions :/
#378
borispetrovdev
started this conversation in
General
Replies: 1 comment
-
yeah I agree, I've also written about it here: #373, I haven't got any response from the maintainer of the library, so I've just fixed the version to the latest v7. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
According to the V8 docs,
useStateAction
is being deprecated., and the suggested alternative is React'suseActionState
. ButuseActionState
doesn't have callbacks (e.g.onSuccess
,onError
) which I use frequently for showing toasts (among other uses).To the author(s) of
next-safe-action
: please consider either 1) not deprecatinguseStateAction
, or 2) adding to the docs an example of how to recreateonSuccess
/onError
withuseActionState
.Beta Was this translation helpful? Give feedback.
All reactions