Getting Started
Overview
Bridging hooks for OP Stack Chains
Features
- Simplifies cross L1 & L2 interactions
- Supports "CustomGasToken" deposit & withdrawal functions
- Supports multi-functionality & new fault-proof feature
- CLI command development tools
Installation
INFO
Recommend: use Nodejs v20+ and add -g
is a global package installation. (guide)
bash
npm i -g opstack-kit
bash
pnpm i -g opstack-kit
bash
bun i -g opstack-kit
bash
yarn add -g opstack-kit
Example
After use opstack-kit/chains
for configuring the network in your app, just import the opstack-kit
hooks to start interacting with OP Stack chains.
tsx
import { useWriteDepositETH } from 'opstack-kit'
const { writeDepositETH } = useWriteDepositETH()
return (
<button
onClick={() =>
writeDepositETH({
args: {
to: '0x215db47f1B2ae03ec45024Cf62ce82879b137469',
amount: 1n,
},
l2ChainId: 11155420,
})}
>
Deposit ETH
</button>
)
Donate
EVM
0xB6Be617b1D6fE5DbdD21A6AcFD9e97A35ddCEfF5