title: How to use react-datepicker with redux form?
body: <p>I'm trying to make react datepicker works with redux-form, I've already read my answers on stackoverflow I made the picker works fine but I can't type anything on the field for some reason. It's interesting that if I try to paste a valid date like 12/30/2019, then it also works. Here is my code</p>
  
  <pre><code>import React from "react";
  import { Field, reduxForm } from "redux-form";
  import DatePicker from "react-datepicker";
  import moment from "moment";
  
  const RenderDatePicker = ({ input }) =&gt; (
    &lt;div&gt;
      &lt;DatePicker
        {...input}
        className="form-control"
        onChange={date =&gt; input.onChange(moment(date).format("MM/DD/YYYY"))}
        selected={input.value ? moment(input.value, "MM/DD/YYYY") : null}
      /&gt;
    &lt;/div&gt;
  );
  
  const SimpleForm = props =&gt; {
    const { handleSubmit, pristine, reset, submitting } = props;
    return (
      &lt;form onSubmit={handleSubmit}&gt;
        &lt;Field name={"datePicker"} component={RenderDatePicker} /&gt;
  
        &lt;button type="submit"&gt;
          Submit
        &lt;/button&gt;
      &lt;/form&gt;
    );
  };
  
  export default reduxForm({
    form: "simple"
  })(SimpleForm);
  </code></pre>