uniquegen
Version:
uniquegen is an package for Node.js projects, enabling the generation of random numbers and words. It offers flexibility and ease of use, making it a valuable tool for developers.
18 lines • 1.07 kB
TypeScript
type num = number;
type bool = boolean;
/**
* This TypeScript function generates a random number ID of a specified length, with the option to
* exclude zero and use a custom set of numbers.
* @param {num} [length=1] - The length parameter is a number that specifies the length of the
* generated number ID.
* @param {bool} [WithZero=true] - A boolean value that determines whether or not the generated number
* can include the digit 0. If set to true, the digit 0 will be included in the possible numbers to
* generate. If set to false, the digit 0 will be removed from the possible numbers to generate.
* @param {num[] | undefined} CustomNumbers - An optional parameter that allows the user to provide a
* custom array of numbers to generate the random number ID from. If not provided, the function will
* use the default array of numbers from 0 to 9.
* @returns a Promise that resolves to a number (num).
*/
export default function GenerateNumberID(length?: num, WithZero?: bool, CustomNumbers?: num[]): num;
export {};
//# sourceMappingURL=NumFunction.d.ts.map