Re: [css-houdini-drafts] [css-typed-om] Shorthands in StylePropertyMap

Representing shorthands as raw `CSSStyleValue` might be problematic for compatibility. Suppose I have code like this (back when `text-decoration` was a longhand):
```
let textDecor = styleMap.get('text-decoration'); // CSSKeywordValue
console.log(textDecor.value); // "underline"
```

When `text-decoration` becomes a shorthand, this code would no longer work:
```
let textDecor = styleMap.get('text-decoration'); // CSSStyleValue
console.log(textDecor.value); // error
```

I think treating shorthands like list-valued properties might avoid this (calling `.get` will return `text-decoration` when it was a longhand, and `text-decoration-line` when it became a shorthand).

-- 
GitHub Notification of comment by darrnshn
Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/643#issuecomment-364599190 using your GitHub account

Received on Friday, 9 February 2018 23:30:33 UTC