@gear-js/react-hooks
Version:
React hooks used across Gear applications
13 lines (12 loc) • 660 B
TypeScript
import { ProgramMetadata } from '@gear-js/api';
import { HexString } from '@polkadot/util/types';
import { SendMessageOptions, UseSendMessageOptions } from '../api';
type UseSendMessageWithGasOptions = UseSendMessageOptions & ({
isMaxGasLimit?: boolean;
} | {
gasMultiplier?: number;
});
type SendMessageWithGasOptions = Omit<SendMessageOptions, 'gasLimit'>;
declare function useSendMessageWithGas(destination: HexString, metadata: ProgramMetadata | undefined, options?: UseSendMessageWithGasOptions): (args: SendMessageWithGasOptions) => void;
export { useSendMessageWithGas };
export type { UseSendMessageWithGasOptions, SendMessageWithGasOptions };