-
Notifications
You must be signed in to change notification settings - Fork 355
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Counters library for incremental token id #507
Comments
Hey there! I don't think a counter library would add much value given its simplicity. I would support though, given its widespread use, the implementation of an auto-incremental ERC721 preset contract along with some docs to guide users into using it. |
I agree that it's quite simple. From a convenience standpoint, however, I wouldn't hate having a Counter lib. Plus, the ReentrancyMock is already using one: https://github.com/OpenZeppelin/cairo-contracts/blob/main/tests/mocks/ReentrancyMock.cairo Either way, +1 to an auto-incremental ERC721 preset. |
The counter library was removed in Solidity, and we haven't seen any demand to implement this in Cairo so I'm closing this issue. |
@ggonzalez94 not anymore with how we define presets. It might be worth adding the option to wizard with |
Motivation
The mint function of the actual ERC721 contract requires a token id:
In most cases, users who want to port their nft collections from mainnet to starknet will need incremental token ids.
Details
Token ids should not be assumed to follow any pattern as described by EIP72.
That's why I propose to introduce a Counters library and a new erc721 preset with updated documentation as it's done for the solidity version.
The text was updated successfully, but these errors were encountered: