Wait A Moment, JavaScript Does Support Multiple Inheritance!
... we are just doing it wrong! Classical Inheritance? We Have Something Better! The main limit about multiple inheritance in JavaScript is the presence of " instanceof " operator. In a prototypal based inheritance objects simply inherits from objects, and class keyword is almost meaningless. // generic constructor function B(){}; // remember the prototype var B1proto = B.prototype; // B instance var b1 = new B; // prototype reassignment B.prototype = { constructor:B }; // remember new prototype var B2proto = B.prototype; // B instance var b2 = new B; alert(b2 instanceof B); // true alert(b1 instanceof B); // false Above snippet demonstrates how inheritance and instanceof are related to the current prototype, rather than the function/constructor itself. In few words, the function is the implicit init method for the current prototype object. The relation, as we could spot with FireFox, is with the prototype and not the used constructor. // FireFox exposes __proto__ // wil...