1.0.4 • Published 4 years ago

rohit-npm v1.0.4

Weekly downloads
-
License
ISC
Repository
-
Last release
4 years ago

rohit-npm

Get a list of Github repositories of specified username sorted by numbers of stars in descending order and last updated time

Installation

# using npm
npm install rohit-npm

# using yarn
yarn add rohit-npm

Usage

# using require
const { getRepos } = require('rohit-npm');

# using import
import { getRepos } from 'rohit-npm';

Example

Using promises:

getRepos({
  username: "gaearon", // provide GitHub username here
  page: 1, // optional property: default value is 1
  per_page: 50, // optional property: default value is 30
}).then((repositories) => console.log(repositories));

Using async/await:

const getRepositories = async function () {
  const repositories = await getRepos({
    username: "gaearon", // provide GitHub username here
    page: 1, // optional property: default value is 1
    per_page: 50, // optional property: default value is 30
  });
  console.log(repositories);
};

getRepositories();
1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago