Skip to content

How can I infer typeof SafeActionResult result? #276

Closed Answered by TheEdoRan
palmmymumu asked this question in Q&A
Discussion options

You must be logged in to vote

To get the data type you can select the data prop from the result object:

type data = InferSafeActionFnResult<typeof action>["data"];

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@palmmymumu
Comment options

@TheEdoRan
Comment options

Answer selected by TheEdoRan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants