You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
I have tried validating struct element which is slice of strings. I've tried using the following functions but somehow they don't work as expected:
"range(min|max)": Range,
"length(min|max)": ByteLength,
"runelength(min|max)": RuneLength,
"stringlength(min|max)": StringLength,
How can you say my slice cannot have more than 5 elements and each element cannot be more than 20 alpha characters?
Can you do this with the validator and using struct tags?
The text was updated successfully, but these errors were encountered:
Hello,
I have tried validating struct element which is slice of strings. I've tried using the following functions but somehow they don't work as expected:
"range(min|max)": Range,
"length(min|max)": ByteLength,
"runelength(min|max)": RuneLength,
"stringlength(min|max)": StringLength,
How can you say my slice cannot have more than 5 elements and each element cannot be more than 20 alpha characters?
Can you do this with the validator and using struct tags?
The text was updated successfully, but these errors were encountered: