- From: Andrea Giammarchi <notifications@github.com>
- Date: Wed, 23 Jun 2021 07:18:12 -0700
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/dom/issues/992/866876600@github.com>
@prettydiff I am not sure I understand your "*solution*" though ... > your example still requires a working knowledge of TreeWalker's internal API make it a module? > your use case demonstrates use of `NodeFilter.SHOW_TEXT` which is part of the standard as `Element.TEXT_NODE` is? > nobody is using this so your proposal is to create "*yet another method nobody will know about*" specially in these days where very few read standard documentation? > Either TreeWalker is not well known or the API is too burdensome for most developers and a new method to learn that nobody would know until it's present at least in MDN is a solution? > There is a substantial value to using a single method that requires a single argument and absolutely no boilerplate. We started with a convoluted boilerplate that was unnecessary already, but here a couple of things I believe you are not considering: * a new proposal means various vendors interested in it * a new proposal means new specs to write and maintain * a new proposal means new documentation in MDN * a new proposal might be not so used like it's been for old proposals, accordingly to your searches (but everyone writing core libraries/frameworks know, or *should* know, the TreeWalker, imho, I myself didn't knew about `createNodeIterator` but then again, it's apparently slightly slower than a TreeWalker) So, when the boilerplate is literally 3 lines of code, how is this proposal worth it, when it'll just create yet another method nobody used or needed to date, adn those that did, rightly solved through a TreeWalker? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/dom/issues/992#issuecomment-866876600
Received on Wednesday, 23 June 2021 14:18:33 UTC