hardhat-storage-layout-diff
v0.0.4
Published
Compare storage layouts between two contracts
Maintainers
Readme
Hardhat Storage Layout Diff
Inspect and compare Solidity smart contract storage layouts.
Installation
yarn add --dev hardhat-storage-layout-diffUsage
Load plugin in Hardhat config:
require('hardhat-storage-layout-diff');Export storage layouts:
yarn run hardhat export-storage-layoutCompare two contracts:
yarn run hardhat storage-layout-compare --a [CONTRACT_A_FULLY_QUALIFIED_NAME] --b [CONTRACT_B_FULLY_QUALIFIED_NAME]Include the optional --a-ref and/or --b-ref arguments to specify the git reference where contracts a and b are defined, respectively.
Compare a contract to an exported JSON layout:
yarn run hardhat storage-layout-check --source [PATH_TO_LAYOUT_JSON] --b [CONTRACT_B_FULLY_QUALIFIED_NAME]