logging "this" logs the contents of the global object but "this.name" logs undefined instead of "kenny". I am using node to execute the script
var name = "kenny";
function nameLogger() {
console.log(this); //is logging the global object
console.log(this.name); //undefined
}
nameLogger();