#![cfg_attr(not(feature = "std"), no_std)]
use ink_lang as ink;
#[ink::contract]
mod XYZ {
#[ink(storage)]
pub struct Xyz {
token_id: u32,
serial_code: String
}
...
}
Error:
serial_code: String
| ^^^^^^ not found in this scope
Based on this - you should use the
String
type included inink!
And include in the correct Cargo.toml file:
(or whatever version is correct for you)