jonroig / emojiurlifier

Drop in JS to automatically switch between Emoji Domain and "regular" versions of a site, depending on the visitor's browser....

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

EmojiURLifier - Progressive Enhancement for Emoji Domains

Automatically switch between Emoji and "Regular" Domains

Example: 😎🌐.ws

... falls back to cooldomain.ws on browsers which don't support Emoji Domains. Or, alternatively, enhances the URL to 😎🌐.ws on browsers which do.

Install

Simple... takes 30 seconds. Just add this to your source code:

<script src="https://i❀️.ws/js/emojiurlifier.js"></script>
<script>
  emojiurlifier('http://yourPunycodedEmojiDomain.ws', 'http://yourRegularDomain.com');
</script>

... or just copy the EmojiURLifier.js source and use it directly on your site or CDN.

Longer Explanation

Medium: Cool Domains for Cool People, Less Cool Domains for Less Cool People: Progressive Enhancement to Emoji Domains

Troubleshooting

  • View the source of 😎🌐.ws as a reference.
  • Both your Emoji Domain and your "regular" domain need to point to the same place.
  • If you've been forwarding your Emoji Domain with a 301 redirect, you might need to restart Chrome

WTF?

A free service from Domain Research Group

Get your own Emoji Domain at: i❀️.ws Emoji Domain Registration

About

Drop in JS to automatically switch between Emoji Domain and "regular" versions of a site, depending on the visitor's browser....


Languages

Language:JavaScript 100.0%