I am using Angular2 and trying to debug in Visual Studio 2015. I have a code snippet like this.
someWebService.then(
resultFromServer =>
{
this.localVariable = resultFromServer;
}) ;
After the web service is called, the control comes back but the value of 'this' is null. Yet it works without throwing any errors.
My question is "Is Visual Studio Debugger unable to resolve 'this' value and hence it shows as null ?" or Is there a different explanation ?
====================
Looks like there is some explanation here.
What's the meaning of "=>" (an arrow formed from equals & greater than) in JavaScript?