Skip to content Skip to sidebar Skip to footer

Passing This From .call() To Arrow Function

I have an arrow function that I am trying to execute with call(). For the sake of simplification, as follows: Operational as expected const func = (e) => { console.log(e) }

Solution 1:

this is not bound in arrow functions, so call() and apply() can only pass in parameters. this is ignored

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions#Invoked_through_call_or_apply

Post a Comment for "Passing This From .call() To Arrow Function"