National Party Month

    github-repos-search

    1.0.1 • Public • Published

    github-repos-search

    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 github-repos-search
     
    # using yarn
    yarn add github-repos-search

    Usage

    # using require
    const { getRepos } = require('github-repos-search');
     
    # using import
    import { getRepos } from 'github-repos-search';

    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();

    Install

    npm i github-repos-search

    DownloadsWeekly Downloads

    12

    Version

    1.0.1

    License

    ISC

    Unpacked Size

    2.29 kB

    Total Files

    3

    Last publish

    Collaborators

    • myogeshchavan97