Adding an emoji to a post


Today I learned…well not exactly today, more like yesterday. Anyway, I figured out how to put emojis on the website. I was writing an article and wanted to end a sentence with a smiley face. I'm using Pelican to generate this site, so my first instinct was to Google "emojis in Pelican." I found source code for a plugin, then a blog explaining how to use it. Problem was, I wasn't doing it exactly the same way as the explanation—I wasn't using a python virtual environment. So one thing and another, the files probably didn't end up where they belonged, or I didn't talk nice enough to Pelican to get it to find them. It didn't work.

More Googling turned up "unicode" in the same result as "emoji." Aha! says I. Get the unicode number and just plug it into the article somehow. I was almost there, you have to convert Unicode numbers to their decimal equivalent for the browser to understand them. So I did and it worked!

Now which is easier, cloning the source code for a plugin, downloading a dependency, python-setuptools, then hoping python will install it, then grabbing a list of emojis and their values, putting it where it belongs, telling Pelican about it in two different places,


look up the emoji online, get the hex code, run a 17 character command to convert it to decimal, and just add a $# and a ; when you paste it in the article? I ask you.

For me, the second method. I'd never remember the markdown short codes from one time to the next–I'd have to look online–so I might as well look up the unicode number instead. I can't see the point of using markdown when it makes things harder. Along the way, though, I did grab the list of all emojis and their unicode numbers for myself, in case the site goes offline.

So how many times will I ever use an emoji in a blog post? Maybe never again.🙂


September 15, 2021: And I haven't used one since.