1.3.0-dune.2 • Published 4 years ago

@dune-network/code-utils v1.3.0-dune.2

Weekly downloads
2
License
MIT
Repository
github
Last release
4 years ago

@dune-network/code-utils

Utilities for parsing and managing EVM-compatible bytecode

Usage

const { parseCode } = require("@dune-network/code-utils");

const contractHexCode = "0x608060...";

// parseCode returns an array of instructions
// Ex.
// [ { pc: 0, name: 'PUSH1', pushData: '0x80' },
//   { pc: 2, name: 'PUSH1', pushData: '0x40' },
//   ... ]
const parsedCode = parseCode(contractHexCode);