- From: Justin Fagnani <notifications@github.com>
- Date: Wed, 26 Jun 2019 20:20:11 -0700
- To: w3c/webcomponents <webcomponents@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Thursday, 27 June 2019 03:20:34 UTC
Since reflecting IDL attributes create HTML attributes on an element when set, and there may be cases where that's undesired, or even disallowed (setting attributes in a constructor) - should some or all of the global attributes have properties added to ElementInternals? And should global attributes going forward be added to ElementInternals? A use case would be an element that wants to perform some initialize a value in a custom element constructor ```js class MyElement extends HTMLElement { constructor() { this.title = 'A Custom Element'; } } ``` This will report an error because the `title` attribute is created. I've seen people hit this with `title` and recently with `ariaPressed` in Safari. `ariaPressed` will be handled by ElementInternals, so should other attributes be to? Looking at the current list of global attributes, including `title` (but excluding `tabindex`, which might be covered differently like in #762) I could possibly see arguments that they're not actually internal and _should_ only be set externally, ie an element shouldn't sprout it's own tooltip, but I'm not sure if or how that's been rationalized yet. -- 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/821
Received on Thursday, 27 June 2019 03:20:34 UTC