This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { createPublicClient, http } from 'viem' | |
// Create a public client for the Ethereum Mainnet network | |
const getPublicClient = (chainId: number) => { | |
return { | |
client: createPublicClient({ | |
transport: http('https://rpc.ankr.com/eth'), | |
}), | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { createPublicClient, http } from 'viem' | |
// Create a public client for the Ethereum Mainnet network | |
const getPublicClient = (chainId: number) => { | |
return { | |
client: createPublicClient({ | |
transport: http('https://rpc.ankr.com/eth'), | |
}), | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//@ts-nocheck | |
/* eslint-disable eslint-comments/disable-enable-pair */ | |
/* eslint-disable no-console */ | |
import { | |
createWalletClient, | |
http, | |
toHex, | |
encodeAbiParameters, | |
type EncodeAbiParametersReturnType, | |
type Hex, |