Maybe `proc toJsString(s: string): cstring {.importjs: 
"String.fromCharCode(...(#))".}`, since strings are arrays of bytes in JS. Not 
sure if it would convert flawlessly back to string though.

Reply via email to