Skip to main content
added 450 characters in body
Source Link
user1693593
user1693593

You can escape the char using \uXXXX x2 (for 32-bit values) format:.

To use UTF-8 strings look into typed arrays and TextEncoder / TextDecoder. They are fairly new so you may need to use polyfill in some browsers.

#Example

document.write('<h1>\uD83C\uDC00</h1>');

You can escape the char using \uXXXX x2 (for 32-bit values) format:

document.write('<h1>\uD83C\uDC00</h1>');

You can escape the char using \uXXXX x2 (for 32-bit values) format.

To use UTF-8 strings look into typed arrays and TextEncoder / TextDecoder. They are fairly new so you may need to use polyfill in some browsers.

#Example

document.write('<h1>\uD83C\uDC00</h1>');

Source Link
user1693593
user1693593

You can escape the char using \uXXXX x2 (for 32-bit values) format:

document.write('<h1>\uD83C\uDC00</h1>');