Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get array of errors #60

Open
normancarcamo opened this issue Jul 9, 2018 · 2 comments
Open

Get array of errors #60

normancarcamo opened this issue Jul 9, 2018 · 2 comments

Comments

@normancarcamo
Copy link

normancarcamo commented Jul 9, 2018

Hi I like the package, it's simple and direct to what I need but I would like to have an array of errors because in my requirements I have to send and Array with the path and the error message because in the UI the client developers rely on the keys of the path of the error to highlight the inputs the users didn't fill correctly, even though we achieve the things by hand in the frontend and in the backend, but the simplicity of this package got my attention and now I'm seeing if this could make our middlewares more thinner.

I see it does but the errors are shallow checked, I mean just at one level and stop the validation at the first error found, it would be nice to have different errors from the same input, for example: min length, max length, must be string, must not be empty, and so on. So all of them checked and not only stopped at the first error.

Thanks.

@eivindfjeldstad
Copy link
Owner

That makes sense. We could have an option for it, at least

@phiphou
Copy link

phiphou commented Sep 4, 2019

No update on this ? Need this option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants