Skip to content

Commit

Permalink
contracts-periphery: add typechain (#2987)
Browse files Browse the repository at this point in the history
* contracts-periphery: add typechain

* ctp: fix depcheck

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
  • Loading branch information
tynes and mergify[bot] committed Jul 12, 2022
1 parent 28bd76a commit 95fc3fb
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/famous-schools-argue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@eth-optimism/contracts-periphery': patch
---

Add typechain with ethers v5 support
2 changes: 2 additions & 0 deletions packages/contracts-periphery/.depcheckrc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ ignores: [
"@eth-optimism/contracts-bedrock",
"@openzeppelin/contracts",
"@openzeppelin/contracts-upgradeable",
"@ethersproject/providers",
"@ethersproject/abi",
"@rari-capital/solmate",
"@types/node",
"hardhat-deploy",
Expand Down
5 changes: 5 additions & 0 deletions packages/contracts-periphery/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import '@nomiclabs/hardhat-ethers'
import '@nomiclabs/hardhat-waffle'
import '@nomiclabs/hardhat-etherscan'
import '@eth-optimism/hardhat-deploy-config'
import '@typechain/hardhat'
import 'solidity-coverage'
import 'hardhat-gas-reporter'
import 'hardhat-deploy'
Expand Down Expand Up @@ -92,6 +93,10 @@ const config: HardhatUserConfig = {
mocha: {
timeout: 50000,
},
typechain: {
outDir: 'dist/types',
target: 'ethers-v5',
},
solidity: {
compilers: [
{
Expand Down
12 changes: 6 additions & 6 deletions packages/contracts-periphery/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,10 @@
"files": [
"dist/**/*.js",
"dist/**/*.d.ts",
"dist/types/*.ts",
"dist/types",
"artifacts/contracts/**/*.json",
"deployments/**/*.json",
"L1",
"L2",
"libraries",
"standards"
"contracts"
],
"scripts": {
"build": "yarn build:hh",
Expand Down Expand Up @@ -71,6 +68,8 @@
"@types/chai": "^4.2.18",
"@types/mocha": "^8.2.2",
"@types/node": "^17.0.21",
"@typechain/ethers-v5": "^10.1.0",
"@typechain/hardhat": "^6.1.2",
"babel-eslint": "^10.1.0",
"chai": "^4.3.4",
"copyfiles": "^2.3.0",
Expand All @@ -92,6 +91,7 @@
"solhint": "^3.3.6",
"solhint-plugin-prettier": "^0.0.5",
"solidity-coverage": "^0.7.17",
"ts-node": "^10.8.2"
"ts-node": "^10.8.2",
"typechain": "^8.1.0"
}
}
8 changes: 8 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3190,6 +3190,14 @@
dependencies:
fs-extra "^9.1.0"

"@typechain/hardhat@^6.1.2":
version "6.1.2"
resolved "https://registry.yarnpkg.com/@typechain/hardhat/-/hardhat-6.1.2.tgz#d3beccc6937d93f9b437616b741f839a8b953693"
integrity sha512-k4Ea3pVITKB2DH8p1a5U38cyy7KZPD04Spo4q5b4wO+n2mT+uAz5dxckPtbczn/Kk5wiFq+ZkuOtw5ZKFhL/+w==
dependencies:
fs-extra "^9.1.0"
lodash "^4.17.15"

"@types/abstract-leveldown@*":
version "5.0.2"
resolved "https://registry.yarnpkg.com/@types/abstract-leveldown/-/abstract-leveldown-5.0.2.tgz#ee81917fe38f770e29eec8139b6f16ee4a8b0a5f"
Expand Down

0 comments on commit 95fc3fb

Please sign in to comment.