Skip to content

Commit b190ff9

Browse files
committed
Update deps
Including to Babel 7
1 parent 694e201 commit b190ff9

10 files changed

+4008
-2789
lines changed

.babelrc

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
2-
"presets": ["es2015"],
3-
"plugins": ["transform-runtime"],
4-
"ignore": "test.js",
2+
"presets": ["@babel/preset-env"],
3+
"plugins": ["@babel/plugin-transform-runtime"],
4+
"ignore": ["test.js"],
55
"env": {
66
"development": {
77
"sourceMaps": "inline"
88
}
99
}
10-
}
10+
}

dist/csprng-bytes-browser.js

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
"use strict";
2+
3+
var csprngBytes = function csprngBytes(count) {
4+
return window.crypto.getRandomValues(new Uint8Array(count));
5+
};
6+
7+
module.exports = {
8+
csprngBytes: csprngBytes
9+
};

dist/csprng-bytes.js

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
"use strict";
2+
3+
var Crypto = require('crypto');
4+
5+
var csprngBytes = function csprngBytes(count) {
6+
return Buffer.from(Crypto.randomBytes(count));
7+
};
8+
9+
module.exports = {
10+
csprngBytes: csprngBytes
11+
};

0 commit comments

Comments
 (0)