There should be no concerns about Unicode here.

JavaScript uses 16 bit (2 byte sequences) to represent the BMP
characters. It was created before UTF-16, so much of the language's
functionality is unaware of code points that are represented by
surrogate pairs (non BMP). String length, for instance, is especially
affected by this. Replacement of characters in this case, though,
should not cause problems. Any characters that fall outside of the BMP
range are represented by pairs of 2 byte sequences where each 2 byte
sequence lies in a set that is disjoint from the BMP byte sequences.