-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Description
Would you consider adding the option to keep some objects as they are? Because when having a complex nested array of data where everything except some certain type of data needs to be arraized this would be really handy.
My first idea would be to just use the existing transformer parameter. If the value is false just skip the arraization and keep the object:
$arraized = $Foil\arraize($products, true, ['My\App\Product'=> false]);
I wouldn't be surprised though if you said wontfix as this breaks the basic assumption that
whatever data you pass to the function at the end of the process, you get an array that contains no objects
Just asking... 😉
Metadata
Metadata
Assignees
Labels
No labels