## Problem I'm encountering an issue with Inertia's forceFormData behavior when submitting file arrays in a Rails app: - `@inertiajs/react: 2.0.17` - `inertia-rails: 3.10` When submitting a payload like: ```js { product: { name: "Test", images: [File1, File2, File3] } } ``` with: ```js router.post('/products', data, { forceFormData: true }) ``` Inertia serializes it into indexed keys: ```js product[images][0]: <File1> product[images][1]: <File2> product[images][2]: <File3> ``` Rails parses this into: ```ruby params[:product][:images] # => { "0" => ..., "1" => ..., ... } ``` …which fails the strong parameters declaration: ```ruby params.require(:product).permit(:name, images: []) ``` The images field gets filtered out and validation errors follow. ## Expected Behavior FormData keys should be serialized as: ```js product[images][]: <File1> product[images][]: <File2> ``` This results in a valid array in Rails: ```ruby params[:product][:images] # => [<UploadedFile>, <UploadedFile>, ...] ``` ## Temporary Workaround We’re currently patching the input server-side: ```ruby def normalize_images_param images = params.dig(:product, :images) return unless images.is_a?(ActionController::Parameters) params[:product][:images] = images.values end ``` This converts the hash back into an array before permitting the field.