Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(core): do not decode entities in HTML #394

Merged

Conversation

vejja
Copy link
Collaborator

@vejja vejja commented Mar 5, 2024

Types of changes

  • Bug fix (a non-breaking change which fixes an issue)
  • New feature (a non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Fixes #393

Currently, cheerio uses the default setting of decodeEntities: true when parsing the HTML document.
This modifies the encoding of special characters (e.g. German umlauts).
This PR changes the option to decodeEntities: false, which prevents cheerio from modifying the original source.

Description

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes (if not applicable, please state why)

@vejja vejja self-assigned this Mar 5, 2024
@vejja vejja linked an issue Mar 5, 2024 that may be closed by this pull request
Copy link

vercel bot commented Mar 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nuxt-security ✅ Ready (Inspect) Visit Preview Mar 5, 2024 6:06pm

@Baroshem
Copy link
Owner

Baroshem commented Mar 6, 2024

I will publish a patch version with this fix but I would like to wait as well for this maybe #395 (comment)

@Baroshem Baroshem merged commit d062b5a into main Mar 7, 2024
5 checks passed
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.

Integrate option to disable Cheerio decodeEntities
2 participants