JSFiddle - React, Tailwind, and code Playground
by karthick6891
HTML
<!--code point-->
Codepoint
JavaScript
let text = "This is a text: ABC";
function translate (char)
{
let diff;
if (/[A-Z]/.test (char))
{
diff = "đť—”".codePointAt (0) - "A".codePointAt (0);
}
else
{
diff = "đť—®".codePointAt (0) - "a".codePointAt (0);
}
return String.fromCodePoint (char.codePointAt (0) + diff);
}
let newText = text.replace (/[A-Za-z]/g, translate);
console.log (newText);
parseInt('000041', 16)
parseInt('000041', 16) + 25
(parseInt('0004a6', 16) - parseInt('0001b3', 16)).toString(16)
(parseInt('01D5D4',16) - parseInt('000041', 16)).toString(16)
(parseInt('000041', 16) + parseInt('01d593',16)).toString(16)
(parseInt('000047', 16) + parseInt('01d593',16)).toString(16)
//https://codepoints.net/mathematical_alphanumeric_symbols?page=2
//https://stackoverflow.com/questions/57827828/javascript-convert-text-to-bold-unicode-charset?noredirect=1#comment102086744_57827828