3 ms·
By "multiple inheritance", I mean children can inherit features from multiple parents, whatever the constraints on those parents may be. Ruby, for example, uses
by extension 15y ago
By "multiple inheritance", I mean children can inherit features from multiple parents, whatever the constraints on those parents may be. Ruby, for example, uses modules for this purpose.
Because JS objects can only have a single prototype, you can't inherit from multiple places orthogonally. If you insert mixins into the prototype chain then they can't be shared between multiple chains, and so aren't really mixins.