The ERC721A_Implementation repository uses the PaulRBerg/foundry-template and implements the ERC721A standard for batch minting.
In order to install the template manually:
forge init my-project --template https://github.com/PaulRBerg/foundry-template
cd my-project
yarn install # install Solhint, Prettier, and other toolsIf this is your first time with Foundry, check out the installation instructions.
This template comes with sensible default configurations in the following files:
├── .commitlintrc.yml
├── .editorconfig
├── .gitignore
├── .lintstagedrc.yml
├── .prettierignore
├── .prettierrc.yml
├── .solhintignore
├── .solhint.json
├── .yarnrc.yml
├── foundry.toml
└── remappings.txt
Here's a list of the most frequently needed commands.
Build the contracts:
$ forge buildDelete the build artifacts and cache directories:
$ forge cleanCompile the contracts:
$ forge buildGet a test coverage report:
$ forge coverageDeploy to Anvil:
$ forge script script/DeployFoo.s.sol --broadcast --fork-url http://localhost:8545The minter is the main smart contract for the collection. It is non-upgradeable contract, which implements the ERC721A token standard, for batch minting.
The mint function is the main function which allows minting tokens. The users can mint multiple assets at once, at a lower transaction fee.
I used Foundry for development, and this repository is created from the PRB's foundry template.
MIT © Andrej Babamov