PSP34 Mintable
This example shows how you can reuse the implementation of PSP34 token with PSP34Mintable extension.
#
How to use this extensionFor your smart contract to use this extension, you only need to implement the PSP34Mintable
trait in your PSP34
smart contract. Add import for brush::contracts::psp34::extensions::mintable::*
, inherit the implementation for PSP34Mintable
trait, where you can also customize (override) the original functions from PSP34Mintable
.
use brush::contracts::psp34::extensions::mintable::*;
impl PSP34Mintable for MyPSP34 {}
And that's it! Your PSP34
is now extended by the PSP34Mintable
extension and ready to use its functions!
You can check an example of the usage of PSP34 Mintable.
You can also check the documentation for the basic implementation of PSP34.