# jQuery-BEShare #

This is a simple jQuery plugin to add social sharing links to your webpage. It supports two modes, as a popup attached to an anchor link, and inline inside a container.

Currently provides the following social shares:

- Facebook
- Twitter
- LinkedIn
- Google+

It also provides Print and Email for convenience.

### [See a demo here](http://brandextract.github.io/jQuery-BEShare/demo/) ###

## Usage ##
```javascript
jQuery('.popup').BEShare({
  'type': 'popup', // or 'inline'
  'targets': ['Facebook', 'Twitter'], // also 'LinkedIn', 'Google+', 'Print', 'Email'
  'class': '', // Class to add to the container
  'prefix': 'icon-', // add prefix to icon class
  'suffix': '',  // add suffix to icon class
  'aria-prefix': 'Share on ',
  'width': '626',
  'height': '436',
  'message': document.title,
  'via': '', // A username associated with the shared content, usually for Twitter
  'onShare': null,  // A function to run when share button is clicked
  'altLink': null  // To share as a different url than the page you are on
});
```

## Building ##
    npm run build

or

    yarn build

# jQuery-BEShare #

This is a simple jQuery plugin to add social sharing links to your webpage. It supports two modes, as a popup attached to an anchor link, and inline inside a container.

Currently provides the following social shares:

- Facebook
- Twitter
- LinkedIn
- Google+

It also provides Print and Email for convenience.

### [See a demo here](http://brandextract.github.io/jQuery-BEShare/demo/) ###

## Usage ##
```javascript
jQuery('.popup').BEShare({
  'type': 'popup', // string - also accepts 'inline'
  'targets': ['Facebook', 'Twitter'], // array - also accepts 'LinkedIn', 'Google+', 'Print', 'Email'
  'class': '', // string - Class to add to the container
  'prefix': 'icon-', // string - add prefix to icon class
  'suffix': '',  // string - add suffix to icon class
  'aria-prefix': 'Share on ',  // adds aria-label parameter to link
  'width': '626', // string - width of the popup
  'height': '436', // string - height of the popup
  'message': document.title, // string - message to share with link
  'via': '', // string - username associated with the shared content, usually for Twitter
  'onShare': null,  // function - to run when share button is clicked
  'altLink': null  // boolean - to use "rel" parameter as the url to share
});
```

## Building ##
    npm run build

or

    yarn build

Make documentation a little more verbose
Make documentation a little more verbose
