@sparshjain/emoji

2.1.0 • Public • Published

Emoji

A simple NPM package which returns emoji by name, random emoji of the given type and a random emoji .

npm (scoped) npm bundle size (scoped version) npm collaborators NPM

Installation

  • Download and install NodeJS
  • Install the package using npm install
$ npm install @sparshjain/emoji

Usage

  • emojiByName( name : String ) returns the emoji of the corresponding name.
  • randomEmojiByType( type : String ) returns a random emoji of the corresponding type.
  • emojiByType( type : String ) returns array of emoji of the corresponding type.
  • randomEmoji() returns a random emoji .
  • Emoji object :
  {
      "name"    : "tears of joy",
      "content" : "😂",
      "type"    : "smiley"
  }

Example

  • Install the package as described above .
const {emojiByName,randomEmoji,randomEmojiByType, emojiByType} = require('@sparshjain/emoji');
console.log(emojiByName('SMILING FACE'));
console.log(randomEmojiByType('activities'));
console.log(emojiByType('food'));
console.log(randomEmoji());

or

  • Clone the repo and run test.js file
$ git clone https://github.com/SparshJain2000/emoji.git
$ cd emoji
$ node test.js

Contributing

🍴 Fork the repository

📝 Change it / add your code

✔️ Do a "pull request"

License

MIT © Sparsh Jain

Support

Give a 🌟 to this repo if you liked it.

Connect with me

Instagram LinkedIn Github

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i @sparshjain/emoji

      Weekly Downloads

      0

      Version

      2.1.0

      License

      MIT

      Unpacked Size

      19.9 kB

      Total Files

      6

      Last publish

      Collaborators

      • sparshjain