ethers.js/utils/random-bytes.js

9 lines
272 B
JavaScript
Raw Permalink Normal View History

2018-06-13 15:39:39 -04:00
'use strict';
Object.defineProperty(exports, "__esModule", { value: true });
2018-06-17 16:47:28 -04:00
var bytes_1 = require("./bytes");
2018-06-15 04:18:17 -04:00
var crypto_1 = require("crypto");
2018-06-13 15:39:39 -04:00
function randomBytes(length) {
2018-06-17 16:47:28 -04:00
return bytes_1.arrayify(crypto_1.randomBytes(length));
2018-06-13 15:39:39 -04:00
}
exports.randomBytes = randomBytes;