I'm trying to use BoundedVec from frame_support
for one of my storage items like this,
pub(super) type Payloads<T: Config> = StorageMap<_, Blake2_128Concat, T::BlockNumber, Vec<Payload>, ValueQuery>;
However I'm confused how to implement BoundedVec
here instead of Vec
as I tried something like this which failed
pub(super) type Payloads<T: Config> = StorageMap<_, Blake2_128Concat, T::BlockNumber, BoundedVec<Payload, 100>, ValueQuery>;
Giving me the error,
error[E0747]: constant provided when a type was expected
Can someone who has already worked on this, give me an example of how to use BoundedVec
?