UNPKG

@cloud-copilot/iam-collect

Version:

Collect IAM information from AWS Accounts

19 lines 600 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.randomCharacters = randomCharacters; const characters = '0123456789abcdefghijklmnopqrstuvwxyz'; /** * Generates a random string of a given length * * @param length The length of the string you would like to generate * @returns */ function randomCharacters(length = 5) { let result = ''; for (let i = 0; i < length; i++) { const randomIndex = Math.floor(Math.random() * characters.length); result += characters[randomIndex]; } return result; } //# sourceMappingURL=strings.js.map