🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

emoji-api

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

emoji-api

Simple Emoji API

3.0.1
latest
Source
npm
Version published
Weekly downloads
16K
-10.43%
Maintainers
1
Weekly downloads
 
Created
Source

EmojiAPI

Simple Emoji API.

Installing

$ npm i emoji-api

Example

// ESM
import * as emoji from "emoji-api";
// CJS
const emoji = require("emoji-api");

console.log(emoji.get("🥺"));

/*
Emoji {
  _data: {
    emoji: '🥺',
    name: 'pleading face',
    group: 'Smileys & Emotion',
    sub_group: 'face-concerned',
    codepoints: '1F97A'
  }
}
*/

console.log(emoji.get("🥺").formattedName); // Pleading Face
console.log(emoji.get("🥺").twemoji()); // https://twemoji.maxcdn.com/v/latest/72x72/1f97a.png

Arrange emojis by category

const { arrange } = require("emoji-api");

console.log(arrange()); // { "Smileys & Emotion": [Emoji, Emoji, ...], ... }

Other Examples

console.log(emoji.all()); // [Emoji, Emoji, Emoji, ...]
console.log(emoji.emojiToUnicode("🥺")); // 1f97a
console.log(emoji.unicodeToEmoji("1f97a")); // 🥺

Keywords

emoji

FAQs

Package last updated on 02 Oct 2022

Did you know?

Socket

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