diff --git a/.gitignore b/.gitignore index d4fb0fccd..90ea633c2 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,8 @@ artifacts/ .openzeppelin/unknown-298.json .env test-results.* +contracts-abi/* +!contracts-abi/contracts ## --- Foundry Gitignore --- diff --git a/hardhat.config.js b/hardhat.config.js index 32c6e7d8a..99a706345 100644 --- a/hardhat.config.js +++ b/hardhat.config.js @@ -18,6 +18,7 @@ * */ +require('hardhat-abi-exporter'); require('@openzeppelin/hardhat-upgrades'); require('@nomicfoundation/hardhat-foundry'); require('@nomicfoundation/hardhat-chai-matchers'); @@ -55,6 +56,10 @@ module.exports = { }, }, }, + abiExporter: { + path: './contracts-abi', + runOnCompile: true, + }, defaultNetwork: NETWORKS.local.name, networks: { local: {