@kyjus25/glo-rxjs-sdk
v1.0.5
Published
JavaScript RxJS SDK for GitKraken Glo APIs
Downloads
3
Readme
GitKraken Glo JavaScript RXJS SDK
GitKraken Glo API documentation
How to Use
Install
npm:
npm install -S @kyjus25/glo-rxjs-sdk
yarn
yarn add @kyjus25/glo-rxjs-sdk
Example Usage
You must pass in an auth token before making calls. All method calls return an observable, so you should properly handle errors with an error handler.
// Import the GloSDK Module
import {GloSDKModule} from '@kyjus25/glo-rxjs-sdk';
@NgModule({
imports: [
GloSDKModule
]
})
export class AppModule {}
// Usage
import {GloSDK} from '@kyjus25/glo-rxjs-sdk';
@Component({
providers: [],
selector: 'pm-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.scss'],
})
export class AppComponent implements OnInit {
constructor(
private gloSDK: GloSDK
}
public ngOnInit() {
this.gloSDK.setAccessToken('my_access_token');
this.gloSDK.boards.get().subscribe(boards => {
console.log(boards);
});
}
}