NaturalIntelligence / fast-xml-parser

Validate XML, Parse XML and Build XML rapidly without C/C++ based libraries and no callback.
https://naturalintelligence.github.io/fast-xml-parser/
MIT License
2.59k stars 309 forks source link

Text is change the Sub Character and its showing like this ᴸᶦᵛᵠ#676

Closed BilalHadid closed 2 months ago

BilalHadid commented 2 months ago

Description

if the text with sub character then it should be display we don't want to change it. Text should should not be change

Input

<programme start="20240905130000 +0000" stop="20240905140000 +0000" channel="ABCWABC.us">
    <title>Live with Kelly and Mark  ᴺᵉʷ</title>
    <desc>S03E03 Carrie Coon (&quot;His Three Daughters&quot;); Daniel Dae Kim (Broadway&apos;s &quot;Yellow Face&quot;); Tamron Hall leads Kelly and Mark in a cooking demo with Lish Steiling.</desc>
</programme>

Code

const parser = new XMLParser(); // The parse function is synchronous but we can still make this function async const result = parser.parse(chunk);

Output

{"desc": "Snap-to-snap 60-minute presentation of a Big Ten Football game.", "title": "B1G Football in 60 ᴸᶦᵛᵉ"}

expected data

{"desc": "Snap-to-snap 60-minute presentation of a Big Ten Football game.", "title": "B1G Football in 60 ᴸᶦᵛᵉ"}

Would you like to work on this issue?

Bookmark this repository for further updates. Visit SoloThought to know about recent features.

github-actions[bot] commented 2 months ago

We're glad you find this project helpful. We'll try to address this issue ASAP. You can vist https://solothought.com to know recent features. Don't forget to star this repo.

amitguptagwl commented 2 months ago

FXP doesn't convert the text by it's own. It might be due to character encoding. Did you try to debug the issue with tagValueProcessor where you should receive raw value

BilalHadid commented 2 months ago

@amitguptagwl Yes I tried to debug and console it its showing the same data and I tried to use he or base 64 but Its not working :(

amitguptagwl commented 2 months ago

when you log it without FXP, do you get the same text you pass or the cnverted one?