Thanks I fixed the things you said in updated gist. Why does text need to return textContent and not innerText?
innerText is a lot more performance heavy and triggers layout to be recalculated. stackoverflow.com/a/35213639/5203655
innerText
AFAIK, innerText is also non-standard (originally IE-only) whereas textContent is part of the standard.
textContent
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Thanks I fixed the things you said in updated gist. Why does text need to return textContent and not innerText?
innerText
is a lot more performance heavy and triggers layout to be recalculated.stackoverflow.com/a/35213639/5203655
AFAIK,
innerText
is also non-standard (originally IE-only) whereastextContent
is part of the standard.