Unicode
NAME¶
unicode - Unicode escapes encoding
DESCRIPTION¶
Encodes each character with its unicode representation and an optional prefix/suffix.
OPTIONS¶
--prefix¶
Prefix string to each encoded character
--suffix¶
Suffix string to each encoded character
--include¶
Characters that should be encoded (can contain 'all', 'utf8' or 'ascii')
--exclude¶
Characters that should not be encoded
--regex¶
Regex override for characters that should be encoded
--lowercase¶
Use lowercase hex digits
--var-length¶
Use variable length encoding
--long¶
Use 8 hex digits instead of 4
EXAMPLES¶
| Sample | Encoded |
|---|---|
hello world |
\u0068\u0065\u006C\u006C\u006F\u0020\u0077\u006F\u0072\u006C\u0064 |
café |
\u0063\u0061\u0066\u00E9 |
日本語 |
\u65E5\u672C\u8A9E |
🚀 |
\u1F680 |