To Reproduce
Steps to reproduce the behavior:
Use this component in a form that has its own state.
Pass a piece of that state to <Autocomplete /> as its defaultValue prop.
Update the state in the form.
Autocomplete doesn't update its selected value accordingly.
In the dcx library replace the contents of example/src/components/AutocompleteDemo.tsx with the following:
Describe the bug In the
<Autocomplete />
component doesn't update if thedefaultValue
prop is changed.Suggested fix:
At around line 368.
To Reproduce Steps to reproduce the behavior: Use this component in a form that has its own state. Pass a piece of that state to
<Autocomplete />
as itsdefaultValue
prop. Update the state in the form. Autocomplete doesn't update its selected value accordingly.In the dcx library replace the contents of
example/src/components/AutocompleteDemo.tsx
with the following:Expected behavior it should update the value passed
Please follow the following instruction to create the new branch:
git checkout release/0.8 git pull git checkout -b 'feature/autocomplete-update-value'