Skip to content

praveenkumar-kalidass/react-social-plugins

Repository files navigation

React Social Plugins

npm version dependencies Status badge devDependency Status badge Downloads Paypal

Install

Install the component using NPM:

$ npm install --save react-social-plugins

Usage

Initialise module

import {
  LinkedinCompanyProfile,
  LinkedinFollowCompany,
  LinkedinLogin,
  LinkedinAddProfile,
  LinkedinProfile,
  LinkedinShare,

  TwitterButton,
  TwitterTweet
} from 'react-social-plugins';

Linkedin Plugins

Twitter Plugins

Linkedin Follow Company

Renders a "Follow" button for a company

<LinkedinFollowCompany
  companyId={12312312}
  counter="top" // Or "right"
  lang="en_US"
/>

Linkedin Login

Renders a "Sign in with LinkedIn" button

<LinkedinLogin
  apiKey="xxxxxxxxxxxxxx"
  authorize
  lang="en_US"
  onError={this.handleError}
  onSuccess={this.handleSuccess}
/>

Linkedin Add Profile

Renders a "Add to profile" button

<LinkedinAddProfile
  lang="en_US"
  task="CERTIFICATION_NAME" // Or "SCHOOL_NAME"
/>

Linkedin Profile

Renders a "Member profile" card

<LinkedinProfile
  lang="en_US"
  profileUrl="http://www.linkedin.com/in/praveenkumar-outlook"
  format="inline" // Or "hover"
  text="Praveenkumar K" // text to show in "hover" format
/>

Linkedin Company Profile

Renders a "Company profile" card

<LinkedinCompanyProfile
  lang="en_US"
  companyId={123123123}
  format="inline" // Or "hover"
  text="Company name" // text to show in "hover" format
/>

Linkedin Share

Render a "Share" button

<LinkedinShare
  apiKey="xxxxxxxxxxxxxx"
  authorize
  lang="en_US"
/>

Twitter Tweet

Renders the Tweet with the conversation

<TwitterTweet
  align='left'
  coversation='none'
  tweetId='xxxxxxxxxxxxxxxx'
  theme='light'
  width={325}
/>

Twitter Button

Renders the Tweet button to either Share, Mention or Hashtag

<TwitterButton
  target="/"
  text="Hello World"
  type="Share"
/>
<TwitterButton
  hashtags="one,two"
  target="username"
  text="Hello World"
  type="Mention"
  size="large"
  via="username"
/>
<TwitterButton
  hashtags="one,two"
  target="username"
  text="Hello World"
  type="Hashtag"
  size="large"
  via="username"
/>

License

MIT License