npm.io
1.0.0 • Published 5 years ago

pin-generator

Licence
MIT
Version
1.0.0
Deps
0
Size
3 kB
Vulns
0
Weekly
0
Stars
1

pin-generator

A simple JavaScript utilty library to generate random pin codes.

Installation

$ yarn add pin-generator

# or

$ npm install pin-generator

Usage


import generatePin from "pin-generator";

generatePin(); // returns a 4-digit pin

You can also specify the number of digits you want by calling the generatePin method with an argument


generatePin(6); // 6-digit pin

License

MIT Eyuel Berga

Keywords