-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
t()
or Trans
with HTML entities
#1537
Comments
Did you already try the unescape option? #1529 |
yeah, I did. { "text": "u&nbps;nás" } <Trans shouldUnescape i18nKey="text" /> The reusult is always the same Primarily, I use NPM package next-i18next (wrapper above react-i18n), I've latest versions. |
🤣🤣 really? I need to manually convert HTML entities? 🙈 LOL. Ok, in this case I stop using this crazy and funny package and write custom implementation based on real translation package ReactIntl. |
If you're interested in having this html entities unescaped without providing a custom unescape function, why do you not contribute with a PR and extends this? https://github.com/i18next/react-i18next/blob/master/src/unescape.js |
@hurvajs77 v11.18.2 should include also the helip... the according PR: #1538 |
🐛 Bug - HTML entities aren't translated
If I use any HTML entity in JSON, so I see output as entity code, not character. Sometimes is required use a special charter as hellip, non-break space etc.
To Reproduce
Expected behavior
I expect that pure HTML will be display as real entity.
Your Environment
The text was updated successfully, but these errors were encountered: