Sorry for the OT message.
On Tue, Jun 11, 2013 at 6:22 PM, Andrea Giammarchi
<[email protected]> wrote:
> We don't have interfaces ... I know, we could have mixins though, compatible
> with @@things too.
>
The concepts of Mixins has cropped up before in discussions and is
used in current JS code ( EventEmitter ).
I was wondering if it was possible to codify it in ES6 or is there
simply no bandwidth/time for that?
class MyClass extends MySuper mixin EventEmitter, Iterable {}
Seems the sensible way to add it to the class syntax and it means you
can still subtype and not use your one and only
code-reuse slot ( extend ) for what is a mixin.
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss