@wagmifan/typechain
v0.0.3
Published
TypeScript bindings types(typechain-types)for @wagmifan/solib contracts
Downloads
8
Maintainers
Readme
@wagmifan/typechain
TypeScript bindings types(typechain-types)for smart contracts
test sample : ./test/Lock.ts
import { ethers } from "hardhat";
import LockArtifact from "../artifacts/contracts/Lock.sol/Lock.json";
import { Lock } from "../typechain-types/Lock";
let dLock: Lock = new ethers.Contract(
LockAddr,
LockArtifact.abi,
signer
) as Lock;
dApp sample($ npm install @wagmifan/solib
) : dapp.ts
import { ethers, BigNumber } from "ethers";
import {abis,typechain-types} from "@wagmifan/solib";
const { Lock } = typechain-types;
let dLock: Lock = new ethers.Contract(
LockAddr,
abis.Lock,
signer
) as Lock;