You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I come across this issue where using groupBy(path(['some', 'path']) will always fail the typechecking as the path definition of path is to return T | undefined. You get the "Type string | undefined does not match....".
I'm not entirely sure of the best way you could handle this as the typing is correct to how path works, but thought it was worth opening an issue to see your thoughts.
For anyone who is stuck on how to make the typechecking pass, you can do something like the below:
Hi,
I come across this issue where using
groupBy(path(['some', 'path'])
will always fail the typechecking as the path definition ofpath
is to returnT | undefined
. You get the "Type string | undefined does not match....".I'm not entirely sure of the best way you could handle this as the typing is correct to how
path
works, but thought it was worth opening an issue to see your thoughts.For anyone who is stuck on how to make the typechecking pass, you can do something like the below:
You can always use
as any
but that's not always an ideal solution. :)The text was updated successfully, but these errors were encountered: