Do you know, there are four ways to calculate the value of ‘this’ inside a JavaScript function? Some pointers about ‘this’ Every function has it’s own ‘this’ An arrow function does not have it’s own ‘this’The value of ‘this’ depends on, how that function is called. The value of ‘this does not depend on how the functionContinueContinue reading “Video – Master JavaScript ‘this’ in 30 Mins”
Tag Archives: this
Video- Master 3 important concepts of JavaScript
In this webinar learn 3 most important concepts of JavaScript. How to calculate the value of ‘this’ inside a function All about object literals function constructors and prototypes https://www.youtube.com/watch?v=F2V7MgehDSY
Video- Why You need the apply() and the call() methods in JavaScript
To pass value of ‘this’ object in a function apply and the call methods are used. https://youtu.be/1nG3FKN3KjU The apply() and the call() methods are used to call a function indirectly. When you call a function using the apply() and the call() methods, that is called Indirect Invocation Pattern . The first parameter is alwaysContinueContinue reading “Video- Why You need the apply() and the call() methods in JavaScript”
What are the Call and Apply Methods in JavaScript
Read full article on the Infragistics blog In JavaScript, the apply() and call() methods execute a function in the context (scope) of the first argument you pass to them. Let’s take a look at them in action to learn more. Say that you have an object person as shown below: https://gist.github.com/debugmodedotnet/11ca4e8d58e602ca93813cef93d9601e And in addition, you have aContinueContinue reading “What are the Call and Apply Methods in JavaScript”