IssueRaiser

Implement `HTMLElement` `innerText`

**jsdom** is a great tool for web scraping. However the `textContent` is a very inconvenient way to get readable text for html2text conversion. There is a wonderful article about usefulness of negligible `innerText` in many cases: http://perfectionkills.com/the-poor-misunderstood-innerText/ The author suggests `getSelection().toString()` as a very slow workaround, but `getSelection` is not implemented in the **jsdom** yet. Could you consider an implementing of the `innerText` in the **jsdom**? The author has done a great exploration about it, he has even added a simple spec at the end.

Posted by vsemozhetbyt on Sep 25, 2015, 12:20 AM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.5,000 issues0 comments

github (Other)

Implement `HTMLElement` `innerText`

vsemozhetbytSep 25, 2015, 12:20 AM

**jsdom** is a great tool for web scraping. However the `textContent` is a very inconvenient way to get readable text for html2text conversion. There is a wonderful article about usefulness of negligible `innerText` in many cases: http://perfectionkills.com/the-poor-misunderstood-innerText/ The author suggests `getSelection().toString()` as a very slow workaround, but `getSelection` is not implemented in the **jsdom** yet. Could you consider an implementing of the `innerText` in the **jsdom**? The author has done a great exploration about it, he has even added a simple spec at the end.

Comments (0)

No comments yet. Start the discussion.

Comment on this issue