react-native-gifted-form
react-native-gifted-form copied to clipboard
GiftedFormManager.reset() Not working properly
When I used to clear the form using GiftedFormManager.reset() It only cleared the state value of the form but display values are not cleared.
how to clear the display values?
help me to fix this issue ASAP.
@dev-vinoth same problem here. @FaridSafi both reset and resetValues doesn't clear display values of the form.
I have the same problem
I guess I have found the reason for this behavior (at least it works for me now). It occurs when you use your own state or redux instead of the GiftedFormManager as described here. You have to use a value prop on your widgets, which refer to your state. When you clear your state, the values of the TextInputs are cleared.
=> When you store the form's value in your own state, the methods of GiftedFormManager do not work.