square / laravel-hyrule

Object-oriented, composable, fluent API for writing validations in Laravel
Apache License 2.0
340 stars 10 forks source link

No support for file nodes #7

Closed dziurka closed 2 years ago

dziurka commented 2 years ago

Hi!

Today I noticed that there is no way to add validation for files. Perhaps some more universal Node class could be used as a fallback for unforeseen types?

bezhermoso commented 2 years ago

Hi @dziurka, thanks for the feedback. It is indeed missing support for files, and I'm working on it now: https://github.com/square/laravel-hyrule/pull/8

As for a more universal node type: although that would be convenient, I feel it would go against the goal of ensuring a level of strictness to rule-sets built via Hyrule. Right now that's achieved with the limited set of type-specific property methods.

bezhermoso commented 2 years ago

Support added, I will cut a release next week.