3 ms·
Very helpful post! I was using flag emojis on a landing page and completely unaware that they weren't being rendered correctly on Windows. The author mentions
by pentacent_hq 2y ago
Very helpful post! I was using flag emojis on a landing page and completely unaware that they weren't being rendered correctly on Windows.
The author mentions a polyfill [1] and the fact that they dislike it's using a CDN. Fortunately, the polyfill can be configured to use a local/self-hosted font:
> polyfillCountryFlags(fontName?: string, fontUrl?: string)
Here's how I added it to my Astro landing page:
https://github.com/pentacent/keila-web/commit/e96ec233eef631ed9ca2c64e9b3b27d1a1153484 https://github.com/pentacent/keila-web/commit/e96ec233eef631...
[1] https://github.com/talkjs/country-flag-emoji-polyfill https://github.com/talkjs/country-flag-emoji-polyfill