Re: Element.style setter

See element.style.cssText 
(http://www.w3.org/TR/DOM-Level-2-Style/css.html#CSS-CSSStyleDeclaration)



-----Message d'origine----- 
From: João Eiras
Sent: Monday, August 27, 2012 11:41 AM
To: www-dom@w3.org
Subject: Element.style setter


Hi !

Opera allows element.style to be set with a css fragment, like

# element.style = 'background:green'

which maps to

# element.setAttribute('style', 'background:green');

Others do not support this (throw an error due to being a read-only
property), but it makes the code less verbose.

How about allowing this in DOM 4 ?

Thanks. 

Received on Monday, 27 August 2012 11:14:09 UTC