@taquito/utils
Advanced tools
Comparing version 5.0.1-beta.2 to 5.1.0-beta.1
@@ -31,2 +31,3 @@ "use strict"; | ||
id: new Uint8Array([153, 103]), | ||
expr: new Uint8Array([13, 44, 64, 27]), | ||
// Legacy prefix | ||
@@ -33,0 +34,0 @@ TZ: new Uint8Array([2, 90, 121]), |
@@ -5,5 +5,11 @@ "use strict"; | ||
var constants_1 = require("./constants"); | ||
var blake = require('blakejs'); | ||
var bs58check = require('bs58check'); | ||
var constants_2 = require("./constants"); | ||
exports.prefix = constants_2.prefix; | ||
function encodeExpr(value) { | ||
var blakeHash = blake.blake2b(exports.hex2buf(value), null, 32); | ||
return b58cencode(blakeHash, constants_1.prefix['expr']); | ||
} | ||
exports.encodeExpr = encodeExpr; | ||
/** | ||
@@ -10,0 +16,0 @@ * |
@@ -31,2 +31,3 @@ import { Buffer } from 'buffer'; | ||
id: new Uint8Array([153, 103]), | ||
expr: new Uint8Array([13, 44, 64, 27]), | ||
// Legacy prefix | ||
@@ -36,3 +37,8 @@ TZ: new Uint8Array([2, 90, 121]), | ||
var blake = require('blakejs'); | ||
var bs58check = require('bs58check'); | ||
function encodeExpr(value) { | ||
var blakeHash = blake.blake2b(hex2buf(value), null, 32); | ||
return b58cencode(blakeHash, prefix['expr']); | ||
} | ||
/** | ||
@@ -390,3 +396,3 @@ * | ||
export { b58cdecode, b58cencode, b58decode, buf2hex, encodeKey, encodeKeyHash, encodePubKey, hex2buf, hexNonce, mergebuf, mic2arr, ml2mic, prefix, sexp2mic }; | ||
export { b58cdecode, b58cencode, b58decode, buf2hex, encodeExpr, encodeKey, encodeKeyHash, encodePubKey, hex2buf, hexNonce, mergebuf, mic2arr, ml2mic, prefix, sexp2mic }; | ||
//# sourceMappingURL=taquito-utils.es5.js.map |
@@ -5,3 +5,3 @@ (function (global, factory) { | ||
(global = global || self, factory(global.taquitoUtils = {}, global.buffer)); | ||
}(this, function (exports, buffer) { 'use strict'; | ||
}(this, (function (exports, buffer) { 'use strict'; | ||
@@ -36,2 +36,3 @@ var prefix = { | ||
id: new Uint8Array([153, 103]), | ||
expr: new Uint8Array([13, 44, 64, 27]), | ||
// Legacy prefix | ||
@@ -41,3 +42,8 @@ TZ: new Uint8Array([2, 90, 121]), | ||
var blake = require('blakejs'); | ||
var bs58check = require('bs58check'); | ||
function encodeExpr(value) { | ||
var blakeHash = blake.blake2b(hex2buf(value), null, 32); | ||
return b58cencode(blakeHash, prefix['expr']); | ||
} | ||
/** | ||
@@ -399,2 +405,3 @@ * | ||
exports.buf2hex = buf2hex; | ||
exports.encodeExpr = encodeExpr; | ||
exports.encodeKey = encodeKey; | ||
@@ -413,3 +420,3 @@ exports.encodeKeyHash = encodeKeyHash; | ||
})); | ||
}))); | ||
//# sourceMappingURL=taquito-utils.umd.js.map |
/// <reference types="node" /> | ||
export { prefix } from './constants'; | ||
export declare function encodeExpr(value: string): any; | ||
/** | ||
@@ -4,0 +5,0 @@ * |
{ | ||
"name": "@taquito/utils", | ||
"version": "5.0.1-beta.2", | ||
"version": "5.1.0-beta.1", | ||
"description": "converts michelson data and types into convenient JS/TS objects", | ||
@@ -63,2 +63,3 @@ "keywords": [ | ||
"dependencies": { | ||
"blakejs": "^1.1.0", | ||
"bs58check": "^2.1.2", | ||
@@ -94,3 +95,3 @@ "buffer": "^5.2.1" | ||
}, | ||
"gitHead": "e09eb813afa12fae51ae3a43e0dc04641c457979" | ||
"gitHead": "eacdf7b79577ed401c726286a782c579ec52c3d2" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
101826
1297
3
+ Addedblakejs@^1.1.0
+ Addedblakejs@1.2.1(transitive)