Closed fakenickels closed 4 years ago
So we can add more data in the validator constructors without hurting usability.
StringMin(Name, 20) StringMax(Name, 20)
would become
string(~min=20, ~max=60, Name)
or
string(~min=20, Name)
or even finally add a label argument for better errors!
string(~min=20, ~label="Nome", Name)
in the end string is just a function that will return an array of the proper constructors for ReSchema
string
And of course we would provide a https://comby.dev script for easy conversion, both syntaxes would still be valid! ✨
Closed by https://github.com/Astrocoders/reform/pull/171
So we can add more data in the validator constructors without hurting usability.
would become
or
or even finally add a label argument for better errors!
in the end
string
is just a function that will return an array of the proper constructors for ReSchema