Skip to content

Latest commit

 

History

History
32 lines (22 loc) · 754 Bytes

README.md

File metadata and controls

32 lines (22 loc) · 754 Bytes

use-emoji

React hook for emoji related things 🎣

NPM JavaScript Style Guide

Install

npm install --save use-emoji

Usage

import React, { Component } from 'react'

import { useEmoji, useSameEmoji } from 'use-emoji'

const Example = () => {
  const randomEmoji = useEmoji()    // returns a random emoji on each rerender
  const sameEmoji = useSameEmoji()  // returns the same emoji on each rerender
  return (
    <div>{randomEmoji}</div>
    <div>{sameEmoji}</div>
  )
}

License

MIT © samrose3