@zilliqa-js/util
Advanced tools
Comparing version 0.2.5 to 0.2.6
import BN from 'bn.js'; | ||
import Long from 'long'; | ||
export declare const isAddress: (address: string) => boolean; | ||
@@ -9,2 +10,3 @@ export declare const isPrivateKey: (privateKey: string) => boolean; | ||
export declare const isBN: (x: unknown) => x is BN; | ||
export declare const isLong: (x: unknown) => x is Long; | ||
export declare const isString: (x: unknown) => x is string; | ||
@@ -11,0 +13,0 @@ export declare const isPlainObject: (x: unknown) => x is { |
@@ -5,2 +5,3 @@ "use strict"; | ||
var bn_js_1 = tslib_1.__importDefault(require("bn.js")); | ||
var long_1 = tslib_1.__importDefault(require("long")); | ||
exports.isAddress = function (address) { | ||
@@ -27,2 +28,5 @@ return exports.isByteString(address, 40); | ||
}; | ||
exports.isLong = function (x) { | ||
return long_1.default.isLong(x); | ||
}; | ||
exports.isString = function (x) { | ||
@@ -29,0 +33,0 @@ return typeof x === 'string'; |
{ | ||
"name": "@zilliqa-js/util", | ||
"version": "0.2.5", | ||
"version": "0.2.6", | ||
"description": "Utilities for working with Zillia.", | ||
@@ -26,3 +26,3 @@ "main": "dist/index.js", | ||
}, | ||
"gitHead": "e8cc5563c95165ffba2fcd7fd3b5b1d0034199a8" | ||
"gitHead": "d39def85377985894f5ba4135fdcb3c15518deac" | ||
} |
import BN from 'bn.js'; | ||
import Long from 'long'; | ||
@@ -31,2 +32,6 @@ export const isAddress = (address: string) => { | ||
export const isLong = (x: unknown): x is Long => { | ||
return Long.isLong(x); | ||
}; | ||
export const isString = (x: unknown): x is string => { | ||
@@ -33,0 +38,0 @@ return typeof x === 'string'; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
1381799
9281
0