[whatwg] Proposal: Add HTMLElement.innerText

Maciej Stachowiak mjs at apple.com
Mon Aug 16 02:39:02 PDT 2010

On Aug 15, 2010, at 10:27 PM, Mihai Parparita wrote:

> On Sun, Aug 15, 2010 at 8:41 PM, Robert O'Callahan <robert at ocallahan.org> wrote:
>> actually a useful and needed feature, we should hear it. Or if someone from
>> Webkit or Opera wants to explain why they added it, that would be useful
>> too.
> FWIW, WebKit has supported innerText since at least when it branched
> from KHTML (so most likely KHTML implemented it even before then):
> http://trac.webkit.org/browser/trunk/WebCore/khtml/dom/html_element.cpp?rev=4#L157

Indeed, we inherited the feature. Though it has also been improved over time to better match IE, and in general to give better fidelity. Much of the same code is shared by other parts of the engine that want the plain text version of some part of a Web page, for example, producing plain text for the clipboard or for assistive technologies via accessibility APIs.


More information about the whatwg mailing list