0.0.2 • Published 3 years ago

storagelens v0.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

StorageLens

StorageLens is a hardhat plugin to help developer to check contract storage layout

What is storage layout

Storage layout represents how the state storage slots are taken inside a ethereum smart contract.

Knowing this is very helpful for contract using upgradeable pattern like TransparentUpgradeableProxy.

Installation

npm install storagelens

Import the plugin in your hardhat.config.js:

require("storagelens");

Or if you are using TypeScript, in your hardhat.config.ts:

import "storagelens";

Tasks

This plugin creates task called 'printStorage'

npx hardhat printStorage [--no-compile] ERC20

This command will generate results like below (depends on ERC20 you used):

layout of @openzeppelin/contracts/token/ERC20/ERC20.sol:ERC20:
_balances [4771][mapping(address => uint256)]
_allowances [4777][mapping(address => mapping(address => uint256))]
_totalSupply [4779][uint256]
_name [4781][string]
_symbol [4783][string]
_decimals [4785][uint8]
0.0.2

3 years ago

0.0.1-g

3 years ago

0.0.1-f

3 years ago

0.0.1-e

3 years ago

0.0.1-d

3 years ago

0.0.1-c

3 years ago

0.0.1-b

3 years ago

0.0.1-a

3 years ago

0.0.1

3 years ago