Fetch data from github with github-api
Create a file github-token.js
to contain your github token to run this demo, with following content:
module.exports = "<your-token>"
And make sure you won't include it to git, or share to others.
Install dependencies:
npm install
Run following commands to try different functions:
npx babel-node --presets node6 src/repos.js
npx babel-node --presets node6 src/gists.js
npx babel-node --presets node6 src/stars.js
npx babel-node --presets node6 src/orgs.js
Some of the github-api urls are blocked or unstable in some countries. If you can't get response in reasonable time, try run the code through proxies.