JS | Sololearn: Learn to code for FREE!



Still confused what is ‘this ’ keyword What does it do Any one plz answer

4/20/2021 6:40:37 PM


3 Answers

New Answer


This key word generally points at global window object but it has different behaviors inside arrow funtions and normal functions , this key word also points at one level heigher scope inside a class , so as you see this has many different behaviors depending on where you are using it


This keyword helps in calling the current object of the class


https://www.sololearn.com/discuss/1084213/?ref=app https://www.sololearn.com/discuss/853511/?ref=app https://www.sololearn.com/discuss/2056597/?ref=app https://www.sololearn.com/discuss/456845/?ref=app https://www.sololearn.com/discuss/2445387/?ref=app https://www.sololearn.com/discuss/190653/?ref=app