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

Convert numeric character references representing < and & into &lt; and &amp; #3

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

brettz9
Copy link

@brettz9 brettz9 commented Dec 23, 2021

fix: convert numeric character references representing < and & into &lt; and &amp;, as otherwise may break well-formedness; fixes #1 ; closes #2

Also ensures a more readable form is returned than I had proposed for #2.

In the first commit, the attribute and attributes values differ here (they remain escaped) than the equivalent for text (which returns &lt; to < and &amp; to &), but this appears to be a preexisting issue.

However, in order to fix that issue, I've added a second commit to address the attribute values not being unescaped when accessed, e.g., by the attribute value.

brettz9 added a commit to brettz9/svgo that referenced this pull request Dec 23, 2021
fix: avoid escaping numeric entities or predefined entities lt and amp

Also allows .idea in .gitignore
@brettz9
Copy link
Author

brettz9 commented Jan 12, 2022

@TrySound : Could you take a look?

@brettz9
Copy link
Author

brettz9 commented Feb 27, 2022

Could I get a review or get an ETA?

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.

Unexpected errors for numeric character references that represent < or &
1 participant