https://github.com/MarketingPipeline/Emoji-Fallback.js
Provide support for emojis on ALL web browsers!
https://github.com/MarketingPipeline/Emoji-Fallback.js
emoji emoji-fallback emoji-polyfill emoji-support emoji-unicode emojis emojis-support front-end front-end-development frontend html javascript modenizer modernizr polyfill twemoji user-experience web-development website
Last synced: about 1 month ago
JSON representation
Provide support for emojis on ALL web browsers!
- Host: GitHub
- URL: https://github.com/MarketingPipeline/Emoji-Fallback.js
- Owner: MarketingPipeline
- License: mit
- Created: 2022-08-07T23:36:37.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2025-06-09T01:55:34.000Z (4 months ago)
- Last Synced: 2025-08-01T21:53:19.407Z (2 months ago)
- Topics: emoji, emoji-fallback, emoji-polyfill, emoji-support, emoji-unicode, emojis, emojis-support, front-end, front-end-development, frontend, html, javascript, modenizer, modernizr, polyfill, twemoji, user-experience, web-development, website
- Language: JavaScript
- Homepage:
- Size: 129 KB
- Stars: 35
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Emoji-Fallback.js
Replaces emoji characters with emoji images on devices that do not have emoji support with image emojis using Twemoji if needed.> Some older device's do not have emoji support and some emojis are shown as text character's like this
☺
or sometimes not all. This script provides support on ALL devices by checking if there is emoji support on the device - if no emoji support is detected, then emoji's are replaced with images. For example:☺
will become replaced with aimg
of a smiley face on a device with no emoji support.
>
> Currently on Windows, most emojis are supported, except for national flags such as 🇺🇸. When such cases are detected, this script will replace only the flag emojis with images.## Example and usage
You can view a demo of Emoji Fallback in use [here.](https://marketingpipeline.github.io/Emoji-Fallback.js)
How to use Emoji-Fallback.js:
```html
Emoji-Fallback.js Basic Example
import {
emojiFallback,
emojiSupported
} from "https://cdn.jsdelivr.net/gh/MarketingPipeline/Emoji-Fallback.js@latest/dist/emoji-fallback.min.js";
!async function() {
const isSupported = emojiSupported();
console.log(`Emoji supported: ${isSupported}`);
if (!isSupported) {
await emojiFallback();
console.log("Emoji's rendered via fallback");
}
}()
emojiFallback();
```
For more advanced usage - see documentation [here](https://github.com/MarketingPipeline/Emoji-Fallback.js/wiki).
## Contributing 
Want to improve this? Create a pull request with detailed changes / improvements! If approved you will be added to the list of contributors of this awesome project!
See also the list of
[contributors](https://github.com/MarketingPipeline/Emoji-Fallback.js/graphs/contributors) who
participate in this project.## License 
This project is licensed under the MIT License - see the
[LICENSE.md](https://github.com/MarketingPipeline/Emoji-Fallback.js/blob/main/LICENSE) file for
details.