Skip to main content
Version: 3.2.0

PSP22 Pallet Burnable

This example shows how you can reuse the implementation of PSP22 token with PSP22Burnable extension via pallet-assets chain extension.

How to use this extension

First, you should implement basic version of PSP22 Pallet.

After you can just add implementation of PSP22PalletBurnable via #[openbrush::implementation(PSP22PalletBurnable)] attribute.

#[openbrush::implementation(PSP22Pallet, PSP22PalletBurnable)]
#[openbrush::contract]
pub mod my_psp22_pallet {
...

And that's it! Your PSP22 Pallet is now extended by the PSP22Burnable extension and ready to use its functions!