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 '{ key: number; } & Pick<T, Exclude<keyof T, "key">>' is not assignable to type 'T'.
'{ key: number; } & Pick<T, Exclude<keyof T, "key">>' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '{ key: number; }'.
TypeScript Version: 3.7.0-dev.20190924
Search Terms: destructure spread generic
Code
Expected behavior:
No type errors
Actual behavior:
Playground Link: https://www.typescriptlang.org/play/index.html?ts=Nightly#code/GYVwdgxgLglg9mABFApgZygHgCqJQD1TABM1EBvAaxQE8AuRMEAWwCMUAnAXwD4AKKrQA0iAHTiO6KFwbYAlLIoBYAFCJEkqCA5JB9RAEYADCPGjJGLqq5A
Related Issues: #26412 #10727 #28234 #28312 #18552
The text was updated successfully, but these errors were encountered: