Re: [w3c/webcomponents] Is there a way to retrieve the localName from a custom element constructor? (#566)

Solution for built-ins:
```webidl
partial interface Window {
  attribute ElementRegistry builtinElements;
};

interface ElementRegistry {
  any get(DOMString name, optional DOMString? namespace = null);
  sequence<ElementName> getNames(any constructor);
};

dictionary ElementName {
  required DOMString name;
  DOMString? namespace = null;
};
```
(It seems we're inconsistent on "builtin". HTML uses a hyphen at the moment, IDL does not.)

-- 
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/566#issuecomment-371049783

Received on Wednesday, 7 March 2018 07:34:25 UTC