const user = {
name: 'John',
greet() {
const getName = () => {
console.log(this.name);
};
getName();
},
farewell: function() {
function getName() {
console.log(this.name);
}
getName();
}
};
user.greet();
user.farewell(); Post #2109
5.75K
CHALLENGE
- 👍 2