harry-potter-names
Version:
Get random Harry Potter names
37 lines (28 loc) • 1.49 kB
Markdown
# harry-potter-names
Get random Harry Potter names.
[](https://travis-ci.org/gmanriqueUy/harry-potter-names)
[](https://codecov.io/gh/gmanriqueuy/harry-potter-names/)
[](http://npm.im/harry-potter-names)
[](https://npm-stat.com/charts.html?package=harry-potter-names&from=2016-07-05)
[](http://opensource.org/licenses/MIT)
## Install
Install with **npm**
```
npm install harry-potter-names --save
```
Or if you prefer **yarn**
```
yarn add harry-potter-names
```
## Usage
```javascript
let harryPotterNames = require('harry-potter-names');
// To get array of all names
console.log(harryPotterNames.all);
// To get a random name (a string, of course)
console.log(harryPotterNames.random());
// The random function accepts a number to get an array of random names
console.log(harryPotterNames.random(5));
```
## Other
This library was developed following [this course](https://egghead.io/courses/how-to-write-an-open-source-javascript-library) made by the amazing [Kent C. Dodds](https://twitter.com/kentcdodds).