You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.
reacts-hooks-helper is a nice compact library that helps with forms and steps management.
When using the useForm() with input of type="file" , I found that the default binding does not preserve the values.
Any insights on how to use the helper with file inputs.
For example
constGetFileData=(props)=>{const{ formData, setForm }=useForm(initialData);// ... some code skippedreturn(<form><inputtype="file"id="inputfile"name="inputfile"onChange={setForm}/></form>);};
For example when I upload a file, say "TestFile.txt"
the resulting formData does not have the file, but instead only has the file name as:
formData = { inputfile: "c:\fakepath\TestFile.txt" }
is there a workaround?
The text was updated successfully, but these errors were encountered:
reacts-hooks-helper is a nice compact library that helps with forms and steps management.
When using the useForm() with input of type="file" , I found that the default binding does not preserve the values.
Any insights on how to use the helper with file inputs.
For example
For example when I upload a file, say "TestFile.txt"
is there a workaround?
The text was updated successfully, but these errors were encountered: