A popup window helper/component for GitHub login.
Inspired by and "coppied" from react-github-login.
http://buildastack.io/ - Top right corner.
$ yarn add github-oauth-popup
import { loginWithGithub } from 'github-oauth-popup';
const params = {
client_id: 'id',
scope: 'read:user'
}
);
loginWithGithub(params).then(res => console.log('Code: ', res.code))
An object that contains the client_id and the scope requested
Options for the popup window
{
height: 1000,
width: 600
}
The auth url
'https://github.com/login/oauth/authorize';
Popup window id
'github-oauth-authorize';
MIT © Jure Sotosek