Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is this in JavaScript?

Answer Posted / hr@tgksolutions.com

this refers to the object that is executing the current function.
• In the global scope, this refers to window (in browsers).
• Inside an object method, this refers to the object itself.
• Inside an arrow function, this is lexically bound (inherits from the surrounding scope).

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If you need to hide the javascript code from the older browser versions, how will you perform it?

978


What is the use of window object?

982


Where can I learn javascript for free?

1114


Can you explain how inheritance works in javascript?

932


What is the use of Void(0)?

1063


How do I retrieve a cookie with a given name using a regular expression?

914


Does apple use javascript?

858


What is closure? Give an example.

1025


What is encodeuri() function?

1054


What is an undefined value in JavaScript?

1076


How to redirect a page to another page in javascript?

996


Explain the difference between call() and apply()?

1022


What is javascript ‘strict mode’?

940


What does javascript do?

887


Does html5 replace javascript?

948