this

this = '๋‚˜'! this๋Š” this๊ฐ€ ์†ํ•ด์žˆ๋Š” ๋ฉ”์†Œ๋“œ๊ฐ€ ์†ํ•ด์žˆ๋Š” ๊ฐ์ฒด๋ฅผ ๊ฐ€๋ฆฌํ‚ด! ๊ฐ์ฒด์˜ ์ด๋ฆ„์ด ๋ฐ”๋€Œ์–ด๋„ ์›๋ž˜์˜ ๋กœ์ง์„ ์œ ์ง€ํ•  ์ˆ˜ ์žˆ์–ด์„œ ์žฌ์‚ฌ์šฉ์— ๋„์›€์ด ๋จ. let kim = { name:'kim', first:10, second:20, sum:function(){ return this.first+this.second; } } console.log("kim.sum()",kim.sum()); //kim.sum() 30
becky(์ง€์€)
'this' ํƒœ๊ทธ์˜ ๊ธ€ ๋ชฉ๋ก