- From: Ara Pehlivanian <ara.pehlivanian@gmail.com>
- Date: Tue, 26 Jun 2007 14:27:34 -0400
- To: "James Craig" <jcraig@apple.com>
- Cc: "Jens Meiert" <jens.meiert@erde3.com>, public-html@w3.org, www-style@w3.org
On 6/26/07, James Craig <jcraig@apple.com> wrote: > > Jens Meiert wrote: > > >> I've realized now that the current spec drops the style attribute for > >> all elements except for the <font>, but I can't understand the > >> reasoning behind those decisions. > > > > And neither do I, and according to my experience as well as the > > discussion on that subject there are several cases why we need to > > keep the "style" attribute. > > Some of the common JavaScript libraries use this for performance and > consistency reasons, too. Prototype, for example, uses the [style] to > toggle style values for a couple reasons. 1) So it doesn't have to > override !important styles, and 2) because when checking the > displayed state, performance of getAttribute is much faster than > getComputedStyle. > > James > >From a strictly pragmatic point of view, dropping the style attribute will break a lot of apps on the web. In particular applications that use the attribute in conjunction with server side injected CSS for dynamic background images, color coding, etc... (whether it's correct to do so or not). Likewise, the as stated by James, a lot of JS libraries (and homegrown JS code) depend on the style attribute from anything like simple show/hide functionality to more complex color fading and position animation. Just my 2 cents, A. -- Ara Pehlivanian Site: http://arapehlivanian.com/ Email & GTalk: ara.pehlivanian@gmail.com MSN: ara_p@hotmail.com Twitter: http://twitter.com/ara_p/ iLike: http://www.ilike.com/user/arapehl LinkedIn: http://www.linkedin.com/in/arapehl Facebook: http://www.facebook.com/profile.php?id=704015025 Flickr: http://www.flickr.com/photos/27496223@N00/
Received on Wednesday, 27 June 2007 18:07:12 UTC