[Feature Request] Get last dirty state of unregistered field (when `destroyOnUnregister` is false)
jedwards1211 opened this issue · comments
Are you submitting a bug report or a feature request?
Feature request
What is the current behavior?
If I register a field foo
, it becomes dirty, and then I unregister it, I can't get the last dirty
state. form.getFieldState('foo')
returns null
.
What is the expected behavior?
I didn't set destroyOnUnregister
and the default value is false
so I kind of expected the field state to be preserved since the field value is. It would be nice to at least have an option to preserve the last field state, since I'll have to hack together some way to do it manually.
What's your environment?
Final Form 4.20.4
Other information
I'm using Final Form for cell values in an infinite scrolling table, and I want to only submit rows that were changed, so I need to be able to know what unmounted rows were changed.