- From: Marat Tanalin <mtanalin@yandex.ru>
- Date: Sat, 05 Oct 2013 16:11:19 +0400
- To: Bjoern Hoehrmann <derhoermi@gmx.net>
- Cc: "www-dom@w3.org" <www-dom@w3.org>
05.10.2013, 14:12, "Bjoern Hoehrmann" <derhoermi@gmx.net>: > * Marat Tanalin wrote: > >> It would be nice to have a native (usable and performant) DOM way for >> retrieving DOM nodes by node type (or, alternatively, by node name). >> >> This could be represented by these two simple methods: >> >> * element.getNodesByType(type) -- to get _all_ nodes >> of specified type contained in the element >> (like `element.getElementsByTagName('*')` for elements); > > Use XPath Thank you for your attention, Bjoern. My message is not about searching for an instantaneous existing solution (nor the mailing list is a forum for questions of such type). My message is a proposal intended to improve the DOM standard in general and to make it more universal and consistent. XPath is not DOM or a part of it. XPath is not as intuitive/easy-to-use as DOM. XPath involves parsing "selector" always. Of course, XPath could still be utilized for polyfilling the proposed DOM features in older XPath-capable browsers.
Received on Saturday, 5 October 2013 12:11:47 UTC