interchain-token-sdk
Version:
SDK for deploying and managing interchain tokens across multiple chains using Axelar network
15 lines (14 loc) • 433 B
JavaScript
import { baseSepolia, optimismSepolia, sepolia } from "viem/chains";
export const validateClientNetwork = (publicClient) => {
const clientChainId = publicClient.chain?.id;
if (clientChainId === baseSepolia.id) {
return;
}
if (clientChainId === optimismSepolia.id) {
return;
}
if (clientChainId === sepolia.id) {
return;
}
throw new Error("Client network is not supported");
};