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
Expected behavior:
Type '{ a: number; c: number; }' is not assignable to type 'C'. Property 'd' is missing in type '{ a: number; c: number; }' but required in type 'B'.
Actual behavior:
No errors are shown. Making b non optional property of type A gives expected error
TypeScript Version: 4.0.5
Search Terms:
array of union types
Code
Expected behavior:
Type '{ a: number; c: number; }' is not assignable to type 'C'. Property 'd' is missing in type '{ a: number; c: number; }' but required in type 'B'.
Actual behavior:
No errors are shown. Making b non optional property of type A gives expected error
Playground Link: https://www.typescriptlang.org/play?#code/C4TwDgpgBAglC8UDeBDAXFAdgVwLYCMIAnAbinwH4McDiSBfAKFEigCEFkBjavQ0qABNetUkxbQAwpzgAfdiUaMuAe0wBnYFB6wiRFCAA8kgHycA2oyjJ0UAKwAabRgBs9B4wC6JIA
Related Issues:
The text was updated successfully, but these errors were encountered: