So i have a string for example like
"HITMAN\u2122 Free Trial"
is there any way i can convert the \u2122 to an actual unicode character so that the string would look like this
"HITMAN™ Free Trial"
Edit: for clarification the first string is an utf-8 string from an api, and i need to parse it for display
Just add {and} around 2122, like this:
let unicode_str = "HITMAN\u{2122} Free Trial";
println!("{}", unicode_str);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With