Will any new features be tied to constructors?

Anne van Kesteren annevk at annevk.nl
Wed Jul 1 13:11:26 UTC 2015


On Wed, Jul 1, 2015 at 2:50 PM, Domenic Denicola <d at domenic.me> wrote:
> I.e., do you see any plausible world in which you're allowed to create a custom element with a custom allocator, instead of the browser-supplied HTMLElement one?

I'm not sure I follow. In a world where custom elements are normal
subclassed objects, they would just call super() from the constructor
to set the browser-supplied bits and then add whatever else is needed
themselves. Or are you saying that super() would fully allocate the
object and prevent adding new private state (or other features tied to
constructors)?


-- 
https://annevankesteren.nl/


More information about the es-discuss mailing list