How to reset a textbox when another dropdown field is changed in redux-form?
I tried using dispatch(change()) syntax but I keep getting the following error:
redux-form/lib/change could not be resolved
Finally found solution for above problem. The
redux-form/lib/change could not be resolved
error got resolved when I removed the import {change} from 'redux-form' statement. Instead now, I am passing the change from the form's props. To dynamically reset the value of Field following statement worked like charm:
dispatch(actions.change('FormName', 'FieldName', '')); Note: Below code did not work for me:
dispatch(change('FormName', 'FieldName', ''));