@grafana/faro-core
Version:
Core package of Faro.
11 lines • 447 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.genShortID = genShortID;
var alphabet = 'abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ0123456789';
function genShortID(length) {
if (length === void 0) { length = 10; }
return Array.from(Array(length))
.map(function () { return alphabet[Math.floor(Math.random() * alphabet.length)]; })
.join('');
}
//# sourceMappingURL=shortId.js.map