1.0.2 • Published 5 years ago
buidler-contract-sizer v1.0.2
Buidler Contract Sizer
Output Solidity contract sizes with Buidler.
Installation
yarn add --dev buidler-contract-sizerUsage
Load plugin in Buidler config:
usePlugin('buidler-contract-sizer');Add configuration under the contractSizer key:
| option | description | default |
|---|---|---|
alphaSort | whether to sort results table alphabetically (default sort is by contract size) | false |
runOnCompile | whether to output contract sizes automatically after compilation | false |
contractSizer: {
alphaSort: true,
runOnCompile: true,
}Run the included Buidler task to output compiled contract sizes:
yarn run buidler size-contractsTypeScript Support
For TypeScript compatibility, add 'node_modules/buidler-contract-sizer/type-extensions.d.ts' to the files array in tsconfig.json.