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
const { prop } = someObj; // destructure
if (prop) { // typeguard test for destructured
someFnThatDontAcceptUndefined( someObj.prop ) // use with dot notation leads to Error
}
Expected behavior:
Typeguard of property accesed via dotted notation would also apply to destructured property and vice versa.
Actual behavior:
Properties destructured to variable are not tied to its value accessed via dotted notation and thus typeguard of one of them is not propagated to the other.
The text was updated successfully, but these errors were encountered:
TypeScript Tools for Visual Studio: 2.0.3.0
Code
this also does not work
Expected behavior:
Typeguard of property accesed via dotted notation would also apply to destructured property and vice versa.
Actual behavior:
Properties destructured to variable are not tied to its value accessed via dotted notation and thus typeguard of one of them is not propagated to the other.
The text was updated successfully, but these errors were encountered: