opstack-kit-chains
Support your OP-Stack network with 'opstack-kit'
important
opstack-kit must be installed.
Installation
`
bash [npm]
npm i opstack-kit-chains
or
```bash [pnpm]
pnpm i opstack-kit-chains
or
`
bash [bun]
bun i opstack-kit-chains
or
```bash [yarn]
yarn add opstack-kit-chains
Currently supported networks
L1
L1 - Testnet |
---|
sepolia |
L1 - Mainnet |
----------- |
mainnet |
L2
L2 - Testnet |
---|
optimismSepolia, baseSepolia |
L2 - Mainnet |
----------- |
optimism, base |
Example
Opstack Kit Chains Quickly customize your network that uses Op Stack chains.
`
ts [main/config.ts]
// main.ts
import { sepolia, optimismSepolia } from 'opstack-kit-chains'
... ... ... const config = getDefaultConfig({ appName: 'My RainbowKit App', projectId: import.meta.env.VITE_SOME_KEY, chains: [sepolia, optimismSepolia], ssr: true, });
------------------------- or -------------------------- // config.ts import { createConfig, http } from 'wagmi' import { sepolia, optimismSepolia } from 'opstack-kit-chains'
export const config = createConfig({ chains: [sepolia, optimismSepolia], transports: { [sepolia.id]: http(), [optimismSepolia.id]: http(), }, })
(or you can use <b>Viem =>2.17.11</b> you just need to add `viem/chains` the relevant chain object to work with `opstack-kit`)
## You can add "opstack-kit-chains" a network at this.
- #### How to
- ##### [1. Create your file and name it in src/chains/definitions. Example: optimismSepolia](https://github.com/opstack-kit/opstack-kit-chains/blob/main/src/chains/definitions/optimismSepolia.ts)
- ##### [2. Add the files and network names you created in src/index.ts below in an orderly fashion.](https://opstack-kit.pages.dev/docs/getting-started.html)
- ##### [3. After that create your PR request.](https://github.com/opstack-kit/opstack-kit-chains/pulls)
## Donate
```EVM [EVM]
0xB6Be617b1D6fE5DbdD21A6AcFD9e97A35ddCEfF5