【文件属性】:
文件名称:octocat.js:用于访问GitHub API的Javascript库
文件大小:53KB
文件格式:ZIP
更新时间:2021-02-03 14:04:39
github nodejs javascript github-api GitHubAPIJavaScript
octocat.js
用于访问GitHub API的Javascript库。
:sparkles: 基于承诺
:sparkles: 支持GitHub Enterprise
:sparkles: 轻松处理分页结果
安装
$ npm install octocat --save
用法
创建一个API客户端
const GitHub = require ( 'octocat' ) ;
// Using an access token
const client = new GitHub ( {
token : 'my-access-token'
} ) ;
// Using an username/password
const client = new GitHub ( {
username : 'SamyPesse' ,
password : 'my-password'
} ) ;
// Connecting to an enterprise version
const client = new GitHub ( {
endpoint : 'https
【文件预览】:
octocat.js-master
----.gitignore(531B)
----.babelrc(63B)
----.eslintrc(71B)
----package.json(987B)
----src()
--------page.js(3KB)
--------client.js(5KB)
--------resources()
--------error.js(1KB)
--------index.js(2KB)
----.travis.yml(79B)
----LICENSE(11KB)
----README.md(7KB)
----.eslintignore(4B)
----HISTORY.md(838B)
----.npmignore(9B)
----test()
--------client.js(105B)
--------installation.js(310B)
--------pagination.js(420B)
--------error.js(641B)
--------organization.js(356B)
--------repository.js(351B)
--------users.js(341B)
--------requests.js(1KB)
--------issues.js(640B)
----yarn.lock(96KB)