- useRoute(amountIn, sourceAsset?, sourceAssetChain?, destinationAsset?, destinationAssetChain?, enabled?, allowedBridges?, swapVenues?, enableSmartSwap?, smartRelay?, config?, isDirectTransfer?): {
amountOut: string;
isLoadingRoute: boolean;
isValidatingRoute: boolean;
refresh: (() => Promise<any>);
routeError: any;
routeKey: null | string;
routeResponse: undefined | {
amountIn: string;
amountOut: string;
destinationAsset: SkipSupportedAsset;
destinationAssetChain: SkipSupportedChainData;
operations: any[];
response: RouteResponse;
sourceAsset: SkipSupportedAsset;
sourceAssetChain: SkipSupportedChainData;
transactionCount: number;
};
} Returns {
amountOut: string;
isLoadingRoute: boolean;
isValidatingRoute: boolean;
refresh: (() => Promise<any>);
routeError: any;
routeKey: null | string;
routeResponse: undefined | {
amountIn: string;
amountOut: string;
destinationAsset: SkipSupportedAsset;
destinationAssetChain: SkipSupportedChainData;
operations: any[];
response: RouteResponse;
sourceAsset: SkipSupportedAsset;
sourceAssetChain: SkipSupportedChainData;
transactionCount: number;
};
}
amountOut: string
isLoadingRoute: boolean
isValidatingRoute: boolean
Readonly
refresh: (() => Promise<any>)
- (): Promise<any>
Returns Promise<any>
routeError: any
Readonly
routeKey: null | string
routeResponse: undefined | {
amountIn: string;
amountOut: string;
destinationAsset: SkipSupportedAsset;
destinationAssetChain: SkipSupportedChainData;
operations: any[];
response: RouteResponse;
sourceAsset: SkipSupportedAsset;
sourceAssetChain: SkipSupportedChainData;
transactionCount: number;
}
React hook to get the Skip Route Quote for an amount, a source token/chain and destination token/chain pair