cosmjs/types/types.d.ts

13 lines
561 B
TypeScript
Raw Normal View History

2020-01-22 23:33:17 +01:00
import { Amount, Token } from "@iov/bcp";
2020-01-22 09:41:48 +01:00
import amino from "@tendermint/amino-js";
export declare type AminoTx = amino.Tx & {
readonly value: amino.StdTx;
};
2020-01-22 23:33:17 +01:00
export declare function isAminoStdTx(txValue: amino.TxValue): txValue is amino.StdTx;
export interface TokenInfo extends Token {
readonly denom: string;
}
export declare type TokenInfos = ReadonlyArray<TokenInfo>;
export declare function amountToCoin(lookup: ReadonlyArray<TokenInfo>, amount: Amount): amino.Coin;
export declare function coinToAmount(tokens: TokenInfos, coin: amino.Coin): Amount;