For below code, in Javascript i got output : The Window
var name = "The Window";
var object = {
name : "My Object",
getNameFunc : function(){
return function(){
return this.name;
};
}
};
console.log(object.getNameFunc()());
but for Node.js , i got below output : undefined
i was confused that , is Node.js use the difference interpreter with javascript?