1.1.4 • Published 8 months ago

randomizedcharacter v1.1.4

Weekly downloads
-
License
ISC
Repository
-
Last release
8 months ago
# Random Character Generator Library

This is a JavaScript library that provides two functions for generating random strings with specified lengths and characteristics.

## Installation

To use this library in your project, you can install it via npm:

```bash
npm install randomizedcharacter 

Usage

lightRandom(charlength)

This function generates a random string of characters with a length specified by charlength. It uses a mix of numbers and lowercase letters.

import { lightRandom } from 'randomizedcharacter';

lightRandom(10)
  .then(randomString => {
    console.log(randomString); // Example output: "a2B5c7d1E9"
  })
  .catch(error => {
    console.error(error);
  });

intensiveRandom(charlength, reshuffleFreq)

This function generates a random string of characters with a length specified by charlength. It allows for reshuffling the character pool at a frequency defined by reshuffleFreq.

import { intensiveRandom } from 'randomizedcharacter';

intensiveRandom(15, 5)
  .then(randomString => {
    console.log(randomString); // Example output: "X1z0kPmJw9y8R7A"
  })
  .catch(error => {
    console.error(error);
  });

Error Handling

Both functions return Promises and will reject with a descriptive error message if there are issues with the input parameters.

Limitations

  • The maximum length for generated strings is 1,000,000 characters.
  • Ensure that charlength is not null, NaN, or 0 when calling these functions.
1.1.4

8 months ago

1.1.3

8 months ago

1.0.3

8 months ago

1.0.2

8 months ago

1.0.1

8 months ago

1.0.0

8 months ago