Closed bhansa closed 8 months ago
Hey there, I am not sure if this is a problem our library aims to tackle. DOMPurify is here to prevent XSS. Can you elaborate how you would see this as something we can fix?
Hi, this may not be directly related to the library but I was wondering if there is any solution to resolve this issue. Hence I found DOMPurify as a option on lot of websites to clean the DOM and render it. I thought of asking it here.
Let me know if that's a fair understnading.
I think this is way outside the scope if what we offer, sorry :slightly_smiling_face:
Background & Context
I have data coming from an api and I am wondering if I can use DOMPurify to render the unicode values properly.
Input
\n
We\u00e2\u0080\u0099re looking for a Customer Success Manager, Scale to join our team of humble \u00e2\u0080\u009cmisfits that fit\u00e2\u0080\u009d.
Given output
The output given by DOMPurify.
Expected output
I am expecting the output will remove or render Unicode values properly.
Let me know the best way to do this.
Supporting stackoverflow question: https://stackoverflow.com/questions/77738308/render-unicodes-in-react-using-dangerously-set-innerhtml