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
{{ message }}
Repository navigation
Partial<T> where T has only optional members should not yield ... has no properties in common with type 'Partial<...>'error #20999
Automatically closing this issue for housekeeping purposes. The issue labels indicate that it is unactionable at the moment or has already been addressed.
Just for reference, this has been fixed by adding & object to the type specification for the first parameter of storeDocumentAsync.
This makes sense: documents are always 'real' objects (not Numbers, Strings etc) and it seems to stop the TypeScript compiler from being overzealous and warning about common properties -- probably because there are common properties such as hasOwnProperty.
Activity
DanielRosenwasser commentedon Jan 4, 2018
I believe this is working as intended as part of weak type checking (#16047).
As a side question, does
myDocumentnot have anidfield? I would thinkMyDocumentwould extend fromResourceat the least.typescript-bot commentedon Jan 20, 2018
Automatically closing this issue for housekeeping purposes. The issue labels indicate that it is unactionable at the moment or has already been addressed.
jcormont commentedon Feb 17, 2018
Just for reference, this has been fixed by adding
& objectto the type specification for the first parameter ofstoreDocumentAsync.This makes sense: documents are always 'real' objects (not Numbers, Strings etc) and it seems to stop the TypeScript compiler from being overzealous and warning about common properties -- probably because there are common properties such as
hasOwnProperty.