The eloquent approach dealing with casts is attractive and takes away the complexity of creating Cabron objects from date columns, converting enums to booleans, parsing JSON to an array, or even Laravel’s custom casts introduced in Laravel 7 that can format your application phone numbers, country codes or anything else you can think of. Have you ever thought about using eloquent attribute casting with request objects?
Try to find the easiest way possible to use this package and make your Laravel Requests castable. We tried our best and I hope we could make the usage as simple as you thought… In the example above the input will be mutated in the following way: For more details see Github documentation.