React Emoji React
A clone (eventually) of slack emoji reactions as a react component
Install
npm install react-emoji-react --save
Use
;;; const emojis = name: 'rage' count: 2 name: 'blush' count: 1 name: 100 count: 3 name: 'grinning' count: 2 ; { super; thisstate = emojis ; } { const emojis = thisstateemojis; this; } { console; const emojis = thisstateemojis; this; } { return <EmojiReact reactions=thisstateemojis onReaction= this onEmojiClick= this /> ; } ;
Args
reactions
- an array of current emoji reactions, reactions are objects containing name and count.onReaction
- fired when a current reaction is clicked.onEmojiClick
- fired when a new emoji is selected.