Socket
Socket
Sign inDemoInstall

rehype-accessible-emojis

Package Overview
Dependencies
7
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    rehype-accessible-emojis

Rehype plugin to make emojis accessible, wrapping emojis in with image role and the emojis name in aria-label>


Version published
Weekly downloads
1.2K
decreased by-14.75%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

rehype-accessible-emojis

As I couldn't get gatsby-remark-a11y-emoji working with gatsby-plugin-mdx I made this rehype version to make emojis accessible by wrapping them in a <span role="image"> with aria-label set to the emojis description based on gemoji.

So

😅

turns into

<span role="img" aria-label="smiling face with open mouth &amp; cold sweat"
  >😅</span
>

Install

yarn add -D rehype-accessible-emojis
# or
npm i -D rehype-accessible-emojis

Usage

// gatsby-config.js
{
  resolve: `gatsby-plugin-mdx`,
  options: {
    rehypePlugins: [require(`rehype-accessible-emojis`)],
  },
}

Keywords

FAQs

Last updated on 30 Dec 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc