Skip to content

Instantly share code, notes, and snippets.

@kitelife
Created April 30, 2015 07:10
Show Gist options
  • Save kitelife/6e85d20731adb7fde449 to your computer and use it in GitHub Desktop.
Save kitelife/6e85d20731adb7fde449 to your computer and use it in GitHub Desktop.
对象之间的继承
function extendCopy(p) {
var c = {};
for (var i in p) {
c[i] = p[i];
}
c.uber = p;
return c;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment