unicode emojis not showing on Chrome

10.6k Views Asked by At

When I insert unicode emojis into a <span> using standard jQuery they don't appear with Chrome (v48), but do with Firefox (v43) and Safari (v9). Compare these screenshots:

CHROME:

Chrome unicode emoji failure

FIREFOX:

Firefox unicode emoji success

Any explanation here?

4

There are 4 best solutions below

0
On BEST ANSWER

The issue is that the span had font-weight:bold. As soon as I put font-weight:normal, the emojis appeared.

0
On

The solution was indeed the combination of all the answers above.

Without the <meta charset utf-8" />, the emoji shows gibberish.

With font-weight: bold, it shows nothing.

With font-weight: 600 it shows bold.

Thanks a lot for asking and answering.

0
On

[] Additionally, if one has this issue and it's not related to the font-weight property, you may need to specify the 'charset' attribute in your head tag;

<html>
    <head>
        <meta charset="UTF-8">
    </head>

    <body>
        <span></span>
    </body>
</html>
2
On

It's actually because of the font weight. Set the font-weight to 200px