Co-authored-by: Krishang <[email protected]> Co-authored-by: Yash <[email protected]> Co-authored-by: Yash <[email protected]>
15 lines
296 B
TypeScript
15 lines
296 B
TypeScript
import fs from "node:fs";
|
|
import { formatAbi } from "abitype";
|
|
|
|
const contract = "ClaimableERC1155";
|
|
|
|
const file = JSON.parse(
|
|
fs.readFileSync(
|
|
`../../../modular-contracts/out/${contract}.sol/${contract}.json`,
|
|
"utf-8",
|
|
),
|
|
);
|
|
const parsed = formatAbi(file.abi);
|
|
|
|
console.log(parsed);
|