JS: Difference Between Reflect.apply vs Function.prototype.apply
Reflect.apply is similar to Function.prototype.apply
Reflect.apply
is intuitive and simpler, in functional programing form.Function.prototype.apply
is confusing, because the actual call form isfName.apply
. Confusing because dotted object/property relation is not the object parent/child relation. 〔see JS: Prototype and Inheritance〕Function.prototype.apply
does not work if a function has a property"apply"
somewhere in its
Compare:
Reflect.apply(f , thisBindingObj, argList)
vs
f.apply(thisBindingObj, argList)