Vue Social
A Vue plugin for social share and oAuth login purposes This is build for a Vue/Webpack setup such as Blue
Quickstart
Install the package
npm i -S vue-social
Use the Vue plugin
// the options passed here are passed by default// you don't have to set them explicitlyVue
Set the auth URLs
This is needed for logging in with the oAuth provider, this assumes you have your own back-end implementation
Vuesocialauth =facebook: 'https://exampledomain.com/api/auth/facebook'twitter: 'https://exampledomain.com/api/auth/twitter'linkedin: 'https://exampledomain.com/api/auth/linkedin'
Usage
// import the social plugin// This resembles a really simple login componentmethods:async {try// fire the social.loginconst result = await social// do something with the result herecatch error// handle error here}