https://github.com/melanieseltzer/pikkr
Pick something random from a list of items.
https://github.com/melanieseltzer/pikkr
chooser javascript pick random rng typescript
Last synced: about 2 months ago
JSON representation
Pick something random from a list of items.
- Host: GitHub
- URL: https://github.com/melanieseltzer/pikkr
- Owner: melanieseltzer
- License: isc
- Created: 2019-02-06T19:46:32.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-02-11T01:34:31.000Z (over 7 years ago)
- Last Synced: 2025-09-20T15:31:09.766Z (9 months ago)
- Topics: chooser, javascript, pick, random, rng, typescript
- Language: TypeScript
- Homepage:
- Size: 111 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pikkr 
> Don't what to choose? pikkr returns a random element from an array, so you don't have to.
## Install
```
$ npm install pikkr
```
## Usage
```js
import pikkr from 'pikkr';
// feed it an array of anything
const result = pikkr(['hi', 2, { name: 'Fred' }]);
console.log(result);
//=> randomly chosen element from the array is returned
```
## License
ISC © [Melanie Seltzer](https://github.com/melanieseltzer)