@cosmjs/tendermint-rpc
Advanced tools
Comparing version 0.24.0-alpha.10 to 0.24.0-alpha.11
@@ -166,2 +166,8 @@ "use strict"; | ||
} | ||
static encode(dateTime) { | ||
var _a, _b; | ||
const millisecondIso = dateTime.toISOString(); | ||
const nanoseconds = (_b = (_a = dateTime.nanoseconds) === null || _a === void 0 ? void 0 : _a.toString()) !== null && _b !== void 0 ? _b : ""; | ||
return `${millisecondIso.slice(0, -1)}${nanoseconds.padStart(6, "0")}Z`; | ||
} | ||
} | ||
@@ -168,0 +174,0 @@ exports.DateTime = DateTime; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.WebsocketClient = exports.HttpClient = exports.VoteType = exports.broadcastTxSyncSuccess = exports.broadcastTxCommitSuccess = exports.SubscriptionEventType = exports.Method = exports.Client = exports.adaptor34 = exports.adaptor33 = void 0; | ||
exports.WebsocketClient = exports.HttpClient = exports.VoteType = exports.broadcastTxSyncSuccess = exports.broadcastTxCommitSuccess = exports.SubscriptionEventType = exports.Method = exports.DateTime = exports.Client = exports.adaptor34 = exports.adaptor33 = void 0; | ||
var adaptors_1 = require("./adaptors"); | ||
@@ -9,2 +9,4 @@ Object.defineProperty(exports, "adaptor33", { enumerable: true, get: function () { return adaptors_1.adaptor33; } }); | ||
Object.defineProperty(exports, "Client", { enumerable: true, get: function () { return client_1.Client; } }); | ||
var encodings_1 = require("./encodings"); | ||
Object.defineProperty(exports, "DateTime", { enumerable: true, get: function () { return encodings_1.DateTime; } }); | ||
var requests_1 = require("./requests"); | ||
@@ -11,0 +13,0 @@ Object.defineProperty(exports, "Method", { enumerable: true, get: function () { return requests_1.Method; } }); |
{ | ||
"name": "@cosmjs/tendermint-rpc", | ||
"version": "0.24.0-alpha.10", | ||
"version": "0.24.0-alpha.11", | ||
"description": "Tendermint RPC clients", | ||
@@ -40,3 +40,3 @@ "contributors": [ | ||
"coverage": "nyc --reporter=text --reporter=lcov yarn test --quiet", | ||
"move-types": "shx rm -rf ./types/* && shx mv build/types/* ./types && rm -rf ./types/testdata && shx rm -f ./types/*.spec.d.ts ./types/*/*.spec.d.ts ./types/*/*/*.spec.d.ts", | ||
"move-types": "shx rm -rf ./types/* && shx mv build/types/* ./types && shx rm -rf ./types/testdata ./types/*.spec.d.ts ./types/*/*.spec.d.ts ./types/*/*/*.spec.d.ts", | ||
"format-types": "prettier --write --loglevel warn \"./types/**/*.d.ts\"", | ||
@@ -50,8 +50,8 @@ "prebuild": "shx rm -rf ./build", | ||
"dependencies": { | ||
"@cosmjs/crypto": "^0.24.0-alpha.10", | ||
"@cosmjs/encoding": "^0.24.0-alpha.10", | ||
"@cosmjs/json-rpc": "^0.24.0-alpha.10", | ||
"@cosmjs/math": "^0.24.0-alpha.10", | ||
"@cosmjs/socket": "^0.24.0-alpha.10", | ||
"@cosmjs/stream": "^0.24.0-alpha.10", | ||
"@cosmjs/crypto": "^0.24.0-alpha.11", | ||
"@cosmjs/encoding": "^0.24.0-alpha.11", | ||
"@cosmjs/json-rpc": "^0.24.0-alpha.11", | ||
"@cosmjs/math": "^0.24.0-alpha.11", | ||
"@cosmjs/socket": "^0.24.0-alpha.11", | ||
"@cosmjs/stream": "^0.24.0-alpha.11", | ||
"axios": "^0.19.0", | ||
@@ -63,5 +63,5 @@ "readonly-date": "^1.0.0", | ||
"devDependencies": { | ||
"@cosmjs/utils": "^0.24.0-alpha.10" | ||
"@cosmjs/utils": "^0.24.0-alpha.11" | ||
}, | ||
"gitHead": "4b4bf0803847b44472db12787bee9f770437370f" | ||
"gitHead": "858bd2e08322fa3304fdd94bfd4f055f20671d6f" | ||
} |
@@ -6,3 +6,2 @@ import { As } from "type-tagger"; | ||
export declare type IntegerString = string & As<"integer">; | ||
export declare type DateTimeString = string & As<"datetime">; | ||
/** | ||
@@ -71,3 +70,4 @@ * A runtime checker that ensures a given value is set (i.e. not undefined or null) | ||
export declare class DateTime { | ||
static decode(dateTimeString: DateTimeString): ReadonlyDateWithNanoseconds; | ||
static decode(dateTimeString: string): ReadonlyDateWithNanoseconds; | ||
static encode(dateTime: ReadonlyDateWithNanoseconds): string; | ||
} | ||
@@ -74,0 +74,0 @@ export declare class Hex { |
export { Adaptor } from "./adaptor"; | ||
export { adaptor33, adaptor34 } from "./adaptors"; | ||
export { Client } from "./client"; | ||
export { DateTime } from "./encodings"; | ||
export { | ||
@@ -5,0 +6,0 @@ AbciInfoRequest, |
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
148691
2361