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
Type 'MapOf<{ foo: string; }>' is not assignable to type 'MapOf<{ foo?: string | undefined; }>'.
Type 'string | undefined' is not assignable to type 'string'.
Type 'undefined' is not assignable to type 'string'.ts(2322)
In fact as string object is more specific than string | undefined, it should be valid.
It seems that the comparison is "swapped"
The text was updated successfully, but these errors were encountered:
jdeniau
changed the title
ObjectLikeMap issue with undefined value
MapOf issue with undefined value
Feb 20, 2023
Memo for myself :
triggers an error
In fact as
string
object is more specific thanstring | undefined
, it should be valid.It seems that the comparison is "swapped"
The text was updated successfully, but these errors were encountered: