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
Currently the compiler fails with the following (playground)
Type 'T1' is not assignable to type 'T2'.
Types of property 'foo' are incompatible.
Type 'number | undefined' is not assignable to type 'number'.
Type 'undefined' is not assignable to type 'number'.
The text was updated successfully, but these errors were encountered:
Suggestion
π Search Terms
inference
β Viability Checklist
My suggestion meets these guidelines:
β Suggestion
It would be nice if typescript could recognize/infer and apply safe guard for the following scenario:
Currently the compiler fails with the following (playground)
The text was updated successfully, but these errors were encountered: