const person = { name: "John" }
function sayHi(age) {
console.log(`${this.name} is ${age}`)
}
sayHi.call(person, 30)
sayHi.bind(person, 30)
Post #2347
1.13K
- 🤯 7
- ❤ 2
CO CodeRoll | Frontend @coderoll · 4.06K subscribers
const person = { name: "John" }
function sayHi(age) {
console.log(`${this.name} is ${age}`)
}
sayHi.call(person, 30)
sayHi.bind(person, 30)