[whatwg] Introducing new elements is expensive

Matthew Raymond mattraymond at earthlink.net
Sat Mar 12 07:55:35 PST 2005


Dean Edwards wrote:
> Anne van Kesteren wrote:
>>  <output value="bar">foo</output>
>>
>>Legacy UAs show "foo" where WF2 UAs show "bar".
> 
> This is not consistent with <textarea>. I think they should behave the 
> same. <output> is effectively a read-only <textarea>.

    Actually, this is not the case. For <textarea>, if you put in HTML 
content inside the element, it treats the contents as PCDATA, so the 
user will see HTML markup inside a multiline textbox. That is not the 
case with <output> in a legacy user agent. Any HTML contents will 
display as HTML in a legacy UA. Yet if we assume the <textarea> model 
for <output>, WF2 UAs will display the underlying markup as text instead 
of rendering it. So, right off the bat, we have a difference in how the 
contents of <output> are rendered between legacy and WF2 user agents.

    Since we can't avoid a difference in rendering unless we 
artificially enforce a no-markup-inside-<output> rule, what does it hurt 
to simply have a |value| attribute to set the .defaultvalue directly?



More information about the whatwg mailing list