4 ms·
Maybe "call" and "apply" belongs to that list? Function.prototype.call(this, argument0, argument1...) Function.prototype.apply(this, [arguments]) // ar
by jQueryIsAwesome 14y ago
Maybe "call" and "apply" belongs to that list?
Function.prototype.call(this, argument0, argument1...)
Function.prototype.apply(this, [arguments]) // array for args.
In a related note I created a variation of .bind that can have its bounded arguments an 'this' overwritten called mixbind, and also the methods .mixcall and .mixapply that can be used to overwrite arguments too (you can use NULL or undefined to left holes):
https://gist.github.com/4303394 https://gist.github.com/4303394
- jpolitz 14y agoYeah, those were mentioned in the post as exception 2, but maybe I should make a note.
- deleted 14y ago[deleted]
- jQueryIsAwesome 14y agoYeah it's mentioned in the article, sorry.