Re: [cssom] CSSStyleDeclaration

On 2/23/12 11:27 AM, Boris Zbarsky wrote:
> On 2/23/12 11:19 AM, Tab Atkins Jr. wrote:
>> On Thu, Feb 23, 2012 at 6:22 AM, Simon Pieters<simonp@opera.com> wrote:
>>> http://dvcs.w3.org/hg/cssom/raw-file/tip/Overview.html/#cssstyledeclaration
>>>
>>>
>>> CSSStyleDeclaration should have a getter that "supports indexed
>>> properties".
>>
>> Yes, the current spec is woefully outdated. In the upcoming update,
>> it should switch to using the getter syntax so it's not necessary to
>> try and list every CSS property.
>
> Note that this brings a behavior difference: the properties end up as
> own properties, not properties on the prototype.
>
> In particular, it makes polyfilling of various sorts more difficult.

One interesting possibility is to put the namegetter on the prototype, 
not on objects directly.  Not sure whether this is desirable, of course, 
and WebIDL doesn't really have a good way to express this (yet?).

-Boris

Received on Thursday, 23 February 2012 17:36:15 UTC