Skip to content

Instantly share code, notes, and snippets.

@robdodson
Created August 9, 2012 18:15
Show Gist options
  • Select an option

  • Save robdodson/3306715 to your computer and use it in GitHub Desktop.

Select an option

Save robdodson/3306715 to your computer and use it in GitHub Desktop.
multiple inheritence in javascript
var Parent1 = function() {
this.name = 'foo';
}
var Parent2 = function() {
this.age = '21';
}
var Child = function() {
Parent1.apply(this, arguments);
Parent2.apply(this, arguments);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment