Unicode to char in code

How can I convert a unicode codepoint to a char in code? I can use the html entity inside the font definition (e.g. "") but doing the same inside code does not work.

All variations of the following do not work:

var c = "";

var c = 0xf059;

How can I do this correctly?