Skip to content

Suggest using textContent instead of innerHTML#138

Merged
manuelpuyol merged 4 commits intomainfrom
suggest-textContent-instead-of-innerHTML
Sep 14, 2021
Merged

Suggest using textContent instead of innerHTML#138
manuelpuyol merged 4 commits intomainfrom
suggest-textContent-instead-of-innerHTML

Conversation

@manuelpuyol
Copy link
Copy Markdown
Contributor

We were suggesting using innerHTML to clear content, but that's the same as textContent = ''.
This PR will block all uses of innerHTML and autocorrect to use textContent instead

@manuelpuyol manuelpuyol requested a review from a team as a code owner September 10, 2021 19:25
Copy link
Copy Markdown
Contributor

@dgreif dgreif left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, I like the change!

Copy link
Copy Markdown

@JoseInTheArena JoseInTheArena left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for putting this together! 🙇🏻‍♂️ I just have a small question about the copy on the docs.

@manuelpuyol
Copy link
Copy Markdown
Contributor Author

per @koddsson request, I removed autocorrection since it was confusing

@manuelpuyol manuelpuyol merged commit e6bf709 into main Sep 14, 2021
@manuelpuyol manuelpuyol deleted the suggest-textContent-instead-of-innerHTML branch September 14, 2021 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants