react-hook-form / input

📋 Wrapper component for controlled inputs
https://react-hook-form.com/api#Controller
158 stars 14 forks source link

When value is set to select, I can no longer select another value #29

Closed marcosfsj closed 4 years ago

marcosfsj commented 4 years ago

When I set a default value to my component, I cannot select a different value after.

To reproduce: 1: Go here: https://codesandbox.io/s/react-hook-form-hookforminput-rzu9s 2: set a default value and see that I cannot reselect another value:

<RHFInput as={

          }
          **value={10}**
          name="Select"
          register={register}
          setValue={setValue}
        />