Re: [csswg-drafts] [css-shadow-parts] Add IDL for partList and partMap

This design for partMap doesn't really work, I'm sorry to say. Dictionaries are not good for representing map data structures; among other things, they cannot be returned from attributes.

I would suggest one of two designs:

- partMap is just a DOMString. It's not a token list, and there's no pre-made structure for it, so just do the natural thing. This is what we do for e.g. `<img>`'s `srcset=""` attribute.
- partMap is a new multimap. For this you'll need something similar to https://xhr.spec.whatwg.org/#interface-formdata (although less complicated since you just need DOMString, not (File or USVString)). This would be quite a bit of work.

I'd suggest just doing the DOMString version for now. We can always add the more complicated version later, with a different name (similar to `className` vs. `classList` or `rel` vs. `relList`).

-- 
GitHub Notification of comment by domenic
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/pull/2475#issuecomment-378398204 using your GitHub account

Received on Tuesday, 3 April 2018 21:02:33 UTC