I have an enum used in one of my account that looks like this:
#[derive(AnchorSerialize, AnchorDeserialize, Clone)]
pub enum ItemType {
Empty,
Folder { folder_mint: Pubkey },
Reference { folder_mint: Pubkey },
External { uri: String },
}
#[account]
pub struct Item {
/// Used as seed
pub folder_mint: Pubkey,
/// Used as seed
pub index: u32,
pub previous_index: u32,
pub creation_timestamp: i64,
pub item_type: ItemType,
}
I know I can export the account like so:
export type Item = IdlAccounts<MyProgram>["item"];
But how can I export the enum type?