foundeo / cfdocs

Repository for the cfdocs.org site.
https://cfdocs.org/
Other
180 stars 341 forks source link

Use text() instead of html() #1629

Closed shaedrich closed 11 months ago

shaedrich commented 11 months ago

To prevent XSS (even though, unlikely) and improve performance (even though, only slightly)

pfreitag commented 11 months ago

yes - I'm a big fan of using innerText instead of innerHTML - thanks for the PR @shaedrich

shaedrich commented 11 months ago

Phew! I was worried it was too little of a change 😅

textContent might be even better 😉 (but I doubt, jQuery has that 🤔 )