You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we are going to use hex escapes or even special characters like ã, á, à in TypeScript targeting Lua, it is important that they are escaped in Lua 5.1’s decimal escape format (\ddd) for better compatibility. This is because Lua 5.1 does not support hexadecimal escapes, and using decimal escapes is the best way to correctly represent UTF-8 bytes.
Currently, even if characters are escaped in hex in TypeScript, they remain special characters in Lua, which can cause compatibility issues and incorrect string interpretation.
I would like to open a GitHub issue to have this considered and fixed, since it affects portability and proper UTF-8 string handling when converting TS code to Lua 5.1.
Activity
RodrigoDornelles commentedon May 13, 2026
The TypeScript function
__TS__StringTrimemit non-ASCII characters.