Re: [w3c/webcomponents] Constructor arguments in custom elements (#605)

We certainly don't want to use the second argument of `createElement` to do this because it's already used for customized builtin in the current spec, people have plans to use it for defining attributes, children, etc...

On the other hand, it might be that we can just expose that second argument in the constructor. That'd let authors do whatever they want to do besides dependency injection like configuring elements for one way or another.

One thing to keep in mind is that there's no equivalent mechanism to do this in HTML because we only have elements and attributes in HTML, and attributes are added after the element is constructed.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/605#issuecomment-260058306

Received on Friday, 11 November 2016 21:22:07 UTC