0
從JavaScript的忍者服用,我看到:額外收益的優勢是什麼?
function bind(context, name) {
return function() {
return context[name].apply(context, arguments);
};
}
是什麼上面的代碼之間的區別?
function bind(context, name) {
return context[name].apply(context, arguments);
}
我很困惑,爲什麼需要額外的回報?
謝謝