Skip to content

Instantly share code, notes, and snippets.

@extrabacon
Last active August 29, 2015 13:57
Show Gist options
  • Save extrabacon/9769199 to your computer and use it in GitHub Desktop.
Save extrabacon/9769199 to your computer and use it in GitHub Desktop.
Standalone _.extend function
function extend(obj) {
Array.prototype.slice.call(arguments, 1).forEach(function (source) {
if (source) {
for (var key in source) {
obj[key] = source[key];
}
}
});
return obj;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment