Open rsodre opened 1 week ago
@rsodre I could work on this since it is yet to be assigned
@rsodre I could work on this since it is yet to be assigned
I'm not an admin on this repository. But I'm already working on it for a personal project, and proposing a PR with my changes.
Feature Request
Add a hook to Origami ERC-721 implementation to customize
token_uri()
.Proposed Solution
ERC721MetadataHooksTrait
, containing a functioncustom_uri()
, that can be implemented by the token contract.erc721_metadata_component::token_uri()
to customize its results.ERC721MetadataHooksEmptyImpl
, an empty implementation that should not affect the standard uri.Alternatives
Teh only way to customize the token uri is to clone
erc721_metadata_component
and use it on the token contract, instead of using Origami's own.Related Code
OpenZeppelin has similar hooks at their ERC721 and ERC20 implementations
Additional context
This hook is required to allow fully on-chain metadata.
If the feature is accepted, would you be willing to contribute it?