Re: [csswg-drafts] [cssom] should custom properties be exposed on computed style declarations? (#1316)

I think `el.style['--my-prop']` should be supported if possible. It’s syntactically nicer and more consistent: we tend to use `el.style.color` and not `.getPropertyValue('color')` or `.setProperty('color', 'red')`.

```js
el.style['--scale'] = 3;
el.style['--scale']; // "3"

// vs.

el.style.setProperty('--scale', 3);
el.style.getPropertyValue('--scale'); // "3"
```

-- 
GitHub Notification of comment by valtlai
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1316#issuecomment-487377826 using your GitHub account

Received on Sunday, 28 April 2019 13:08:37 UTC