hgdfhjvysger
v3.3.2
Published
A library to generate pseudo-random values.
Downloads
11
Maintainers
Readme
hgdfhjvysger
A library to generate pseudo-random values.
Installation
npm:
npm install hgdfhjvysger
html / vanilla js:
<!-- jsdelivr -->
<script src="https://cdn.jsdelivr.net/npm/hgdfhjvysger"></script>
<!-- unpkg -->
<script src="https://unpkg.com/hgdfhjvysger"></script>
Example
const random = require("hgdfhjvysger");
random.string(5, "abcde"); // returns string with 5 random characters from 'abcde'
random.fromArray([1, 2, 3, 4, 5]); // returns random value from [1, 2, 3, 4, 5]
random.number(5); // returns random number between 0 and 5 (inclusive)
random.color.hex(); // returns a random hex color in css
random.coin(); // returns 'heads' or 'tails'
Links
- Github
- Discord: sertdfyguhi#5971
Changelog
https://github.com/sertdfyguhi/hgdfhjvysger/blob/main/CHANGELOG.md