Skip to content

Instantly share code, notes, and snippets.

@dashcraft
Created July 12, 2017 20:10
Show Gist options
  • Save dashcraft/4b3853e558eaec656123342d1174912c to your computer and use it in GitHub Desktop.
Save dashcraft/4b3853e558eaec656123342d1174912c to your computer and use it in GitHub Desktop.
A component for linkedin Oauth rest api
import { Component } from '@angular/core';
@Component({
selector: 'LinkedInExample',
template: '<a [href]="url">LinkedIn</a>'
})
export class LinkedInExample{
client_id: String = 'InputYourStupidClientStringHere';
redirect_uri:String = encodeURI("http://localhost:5000/whateverthehell");
url: String = `https://www.linkedin.com/oauth/v2/authorization?response_type=code&client_id=${this.client_id}&redirect_uri=${this.redirect_uri}`;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment