Does pure
allow returning string (or arrays of strings)?
#1339
Answered
by
davidkpiano
keithlayne
asked this question in
General
-
In TS this seems to be a type error. My assumption was that a named action would be a valid return from |
Beta Was this translation helpful? Give feedback.
Answered by
davidkpiano
Jul 28, 2020
Replies: 1 comment 2 replies
-
It expects: The workaround here is to wrap it in an object: |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
keithlayne
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It expects:
SingleOrArray<ActionObject<TContext, TEvent>> | undefined
The workaround here is to wrap it in an object:
{ type: 'yourAction' }
, which is more explicit anyway.