Skip to content

Instantly share code, notes, and snippets.

View ljharb's full-sized avatar
🔜
working on that thing you asked about

Jordan Harband ljharb

🔜
working on that thing you asked about
View GitHub Profile
Function.prototype.within = function (millis) {
var that = this;
return function () {
var args = Array.prototype.slice.call(arguments); // if sinful present, slice(arguments)
return window.setTimeout(function () { that.apply(null, args); }, millis); );
};
};