Name
global.FunctionPolyfill
Description
Implementation of standard Function method bind().
Script
var FunctionPolyfill;
// Simple home-grown polyfill for bind().
if (!Function.prototype.bind) {
Function.prototype.bind = function(_this) {
var fn = this,
args = Array.prototype.slice.call(arguments, 1);
return function() {
return fn.apply(_this, args.concat(Array.prototype.slice.call(arguments)));
};
};
}
Sys ID
b47a2b3a93400200e4e4705bb47ffb25