these contract have been altered for proof of concept and they are diffrent than the proposed Implementation. please see this link to learn more about mechanism and rationale
The upper limit of totalSupply
of any ERC721 contract or how many NFT can be minted, is determined by the EIP-721 is uint256
number.
a quote from EIP-721:
NFT Identifiers
Every NFT is identified by a unique uint256 ID inside the ERC-721 smart contract.
interface ERC721Enumerable
function totalSupply() external view returns (uint256);
and uint256
is an unsigned (it means numbers equal to zero or greater) integer number, with 256 bit. and the range of uint256 is integer number from 0 ~ 2**256 -1.
so the upper limit for totalSupply is this number: 115792089237316195423570985008687907853269984665640564039457584007913129639935
In my Implementation proposal I've talked about how this can be reached:
I've deployed a contract on goerli for proof of concept.
goerli Limits of NFT: 0x6d04C3F8e618a2404803Ca72f5dF93f4F50CaD45
this token is Fully IERC721 and IERC721Enumerable compatible. I highly recomnd you try it for yourself.
from blanceOf() to ownerOf()
even tokenOfOwnerbyIndex().
All of these tokens are minted to "giver" contract that you can grab one for yourself.
- by calling the getToken() you will get a token from index of
0
of the preOwner(giver address). - by calling the getTokenInd(Index) you will get a token from index of
Index
of the preOwner(giver address).
giver goerli : 0x65c94c08Dd504a199fE61C3D29ca01784C7081aF
for proof of concept this contract have an SVG Image with tokenId on it.
the Image:
this project shows:
- limit of uint256 for totalSupply for ERC721 can be reached.
- zero transaction minting is possible.
- batch minting via EIP-2309 and IERC721Enumerable is possible.
Ethereum magician: Use zero gas(0 gwei) for minting any number of NFT