Skip to content

Commit

Permalink
Updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
IonicaBizau committed May 25, 2016
1 parent 2e06ad9 commit 260d405
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 10 deletions.
4 changes: 3 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ Contributions are more than welcome!

Thanks! :sweat_smile:



[1]: https://github.com/IonicaBizau/sort-github-user-repos/issues

[2]: https://github.com/IonicaBizau/code-style
[2]: https://github.com/IonicaBizau/code-style
15 changes: 15 additions & 0 deletions DOCUMENTATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
## Documentation

You can see below the API reference of this module.

### `sortByStars(username, token, callback)`
Sorts the user repos by stars.

#### Params
- **String** `username`: The GitHub username.
- **String** `token`: An optional access token.
- **Function** `callback`: The callback function.

#### Return
- **gh.js** The `gh.js` instance.

25 changes: 16 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
# sort-github-user-repos [![PayPal](https://img.shields.io/badge/%24-paypal-f39c12.svg)][paypal-donations] [![Version](https://img.shields.io/npm/v/sort-github-user-repos.svg)](https://www.npmjs.com/package/sort-github-user-repos) [![Downloads](https://img.shields.io/npm/dt/sort-github-user-repos.svg)](https://www.npmjs.com/package/sort-github-user-repos) [![Get help on Codementor](https://cdn.codementor.io/badges/get_help_github.svg)](https://www.codementor.io/johnnyb?utm_source=github&utm_medium=button&utm_term=johnnyb&utm_campaign=github)

# sort-github-user-repos

[![PayPal](https://img.shields.io/badge/%24-paypal-f39c12.svg)][paypal-donations] [![AMA](https://img.shields.io/badge/ask%20me-anything-1abc9c.svg)](https://github.com/IonicaBizau/ama) [![Version](https://img.shields.io/npm/v/sort-github-user-repos.svg)](https://www.npmjs.com/package/sort-github-user-repos) [![Downloads](https://img.shields.io/npm/dt/sort-github-user-repos.svg)](https://www.npmjs.com/package/sort-github-user-repos) [![Get help on Codementor](https://cdn.codementor.io/badges/get_help_github.svg)](https://www.codementor.io/johnnyb?utm_source=github&utm_medium=button&utm_term=johnnyb&utm_campaign=github)

> Sort GitHub repositories by stars for user.
## Installation
## :cloud: Installation

```sh
$ npm i --save sort-github-user-repos
```

## Example

## :clipboard: Example



```js
const sortGhRepos = require("sort-github-user-repos")
Expand Down Expand Up @@ -67,7 +73,8 @@ sortGhRepos("alysonla", (err, repos) => {
// 0 ⭐ alysonla/httparty
```

## Documentation
## :memo: Documentation


### `sortByStars(username, token, callback)`
Sorts the user repos by stars.
Expand All @@ -80,13 +87,13 @@ Sorts the user repos by stars.
#### Return
- **gh.js** The `gh.js` instance.

## How to contribute


## :yum: How to contribute
Have an idea? Found a bug? See [how to contribute][contributing].

## Where is this library used?
If you are using this library in one of your projects, add it in this list. :sparkles:

## License
## :scroll: License

[MIT][license] © [Ionică Bizău][website]

Expand All @@ -96,4 +103,4 @@ If you are using this library in one of your projects, add it in this list. :spa
[license]: http://showalicense.com/?fullname=Ionic%C4%83%20Biz%C4%83u%20%3Cbizauionica%40gmail.com%3E%20(http%3A%2F%2Fionicabizau.net)&year=2014#license-mit
[website]: http://ionicabizau.net
[contributing]: /CONTRIBUTING.md
[docs]: /DOCUMENTATION.md
[docs]: /DOCUMENTATION.md

0 comments on commit 260d405

Please sign in to comment.