Created
July 9, 2024 12:43
-
-
Save pmatsinopoulos/20ad81ee37a7f3c7009e73c7f86a8694 to your computer and use it in GitHub Desktop.
Hardhat configuration to connect to optimism via Alchemy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { HardhatUserConfig, vars } from "hardhat/config"; | |
import "@nomicfoundation/hardhat-toolbox"; | |
const ALCHEMY_API_KEY = vars.get("ALCHEMY_API_KEY"); | |
const ACCOUNT_PRIVATE_KEY = vars.get("ACCOUNT_PRIVATE_KEY") | |
const config: HardhatUserConfig = { | |
solidity: "0.8.24", | |
networks: { | |
optimism: { | |
url: `https://opt-mainnet.g.alchemy.com/v2/${ALCHEMY_API_KEY}`, | |
accounts: [ACCOUNT_PRIVATE_KEY], | |
}, | |
}, | |
}; | |
export default config; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment