0.2.1 • Published 4 years ago

@sivanarayanan93/rocket-reactions v0.2.1

Weekly downloads
-
License
-
Repository
-
Last release
4 years ago

Rocket Reactions

Github

Dependencies

Installation:

yarn add @sivanarayanan93/rocket-reactions

or

npm i @sivanarayanan93/rocket-reactions

Rocket Reactions requires React 17.0.2+

Reactions

Example:

  import React from 'react';
  import { RocketReactions } from '@sivanarayanan93/rocket-reactions';

  const Component = () => {
    return (
      <RocketReactions />
    )
  }

Props:

reactions: Array of reaction value. Defaults: ['Like', 'Love', 'Haha', 'Wow', 'Sad', 'Angry']

onSelect: Callback function when emoji is selected - Output arg: 'like'

userId: Id of logged-in user

Summary: Array of reacted reactions with reactors

  Ex:

  [{
    emoji: 'Like',
    users: [{
      id, name, avatar(optional)
    }]
  }]

Global styles

  import React from 'react';
  import { RocketReactions, GlobalStyles } from '@sivanarayanan93/rocket-reactions';

  const Component = () => {
    return (
      <GlobalStyles />
      <RocketReactions />
    )
  }
0.2.1

4 years ago

0.2.0

4 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago