sveltekit-superforms
sveltekit-superforms copied to clipboard
Putting dataType: 'json' to enable nested data in a enctype="multipart/form-data" always return value from input type="file" undefined
In my SvelteKit project, I'm using SvelteKit-Superforms to handle form submissions. The form includes a nested data structure and an image upload field, with enctype="multipart/form-data" set to handle file uploads. However, when I set dataType: 'json', the image field always returns undefined and the image never reaches the server. This issue occurs despite the correct configuration of the form and the expected behavior of handling multipart data.
Hi, that feature is tested and just confirmed to pass, so I'll need a MRE to see the difference. You can use one of the templates here, but please check with the test first if you've overlooked something.
Thanks @ciscoheat , I didn't see that example!