useFieldArray's update() and replace() reset Dirtyfields in Edit
This is a wierd one.
When using update() or replace() method from useFieldArray. The Dirtyfields do get reset while in <Edit> View which seems wrong. Same scenario in <Create> View works, however.
Steps to reproduce:
Visit codesandbox i prepared: https://codesandbox.io/p/github/capsloq/form-react-hook-form-use-steps-form
1. Click
2. Type something into Title Field
3. Go To Step 2 by clicking Next
4. Klick "klick this to use update()" button
5. Notice that title is still dirty after clicking the button
6. If you go back to Step 1 you will see that the Title you typed is still there.
Now go back to all posts (/posts)
1. Click on the
2. Type something into Title Field
3. Go To Step 2 by clicking Next
4. Klick "klick this to use update()" button
5. Notice that title is not dirty anymore after clicking the button and the value form Step 1 is lost
Is that intentional or whats happening here?
I was not able to reproduce that with the original react-hook-form.
Thank you
When using update() or replace() method from useFieldArray. The Dirtyfields do get reset while in <Edit> View which seems wrong. Same scenario in <Create> View works, however.
Steps to reproduce:
Visit codesandbox i prepared: https://codesandbox.io/p/github/capsloq/form-react-hook-form-use-steps-form
1. Click
Create Post2. Type something into Title Field
3. Go To Step 2 by clicking Next
4. Klick "klick this to use update()" button
5. Notice that title is still dirty after clicking the button
6. If you go back to Step 1 you will see that the Title you typed is still there.
Now go back to all posts (/posts)
1. Click on the
Edit Button of one post2. Type something into Title Field
3. Go To Step 2 by clicking Next
4. Klick "klick this to use update()" button
5. Notice that title is not dirty anymore after clicking the button and the value form Step 1 is lost
Is that intentional or whats happening here?
I was not able to reproduce that with the original react-hook-form.
Thank you

