[csswg-drafts] [cssom] Parsing value should not be seen as side effects free (#6451)

cdoublev has just created a new issue for https://github.com/w3c/csswg-drafts:

== [cssom] Parsing value should not be seen as side effects free ==
I'm trying to implement `CSSStyleDeclaration` in JS. [Parse a CSS value](https://drafts.csswg.org/cssom/#parse-a-css-value) is invoked by `setProperty` (step 5) with the following steps:

> 1. Let list be the value returned by invoking parse a list of component values from value.
> 2. Match list against the grammar for the property property in the CSS specification.
> 3. If the above step failed, return null.
> 4. Return list.

How can `getPropertyValue('flex-grow')` return `0` after `setProperty(flex, 'none')` if step 2 doesn't mutate the list (or returns a new list)? If it seems too obvious to add a dedicated note below these steps, please forgive me. I could have posted the following issue on StackOverflow but based on my previous experiences with this kind of topic, I don't think anyone would have answered it.

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6451 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 14 July 2021 13:35:10 UTC