Skip to content
Discussion options

You must be logged in to vote

I think the issue is your use of String in the attribute. Try replacing it with a _ like
#[serde_as(as = "HashMap<_, OneOrMany<_>>")]. Unfortunately if you want to use the normal serialization behavior of a type you have to use _ since just writing the type will lead to the error you report.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by jonasbb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants