tiny-secp256k1
Advanced tools
Comparing version
function get4RandomBytes() { | ||
const bytes = new Uint8Array(4); | ||
window.crypto.getRandomValues(bytes); | ||
if (typeof crypto === "undefined") { | ||
throw new Error("The crypto object is unavailable. This may occur if your environment does not support the Web Cryptography API."); | ||
} | ||
crypto.getRandomValues(bytes); | ||
return bytes; | ||
@@ -5,0 +8,0 @@ } |
{ | ||
"name": "tiny-secp256k1", | ||
"version": "2.2.1", | ||
"version": "2.2.3", | ||
"description": "A tiny secp256k1 JS", | ||
@@ -39,2 +39,4 @@ "homepage": "https://github.com/bitcoinjs/tiny-secp256k1#readme", | ||
"devDependencies": { | ||
"@babel/eslint-parser": "^7.22.5", | ||
"@babel/plugin-syntax-import-assertions": "^7.22.5", | ||
"@types/node": "^14.14.35", | ||
@@ -41,0 +43,0 @@ "@typescript-eslint/eslint-plugin": "^4.18.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1283
0.47%223237
-10.51%21
10.53%