Skip to content
This repository has been archived by the owner on Nov 16, 2018. It is now read-only.

Warning: Failed prop type: Invalid prop dateTime supplied to DateTimeField. #204

Open
Raman16 opened this issue Jul 26, 2017 · 0 comments
Open

Comments

@Raman16
Copy link

Raman16 commented Jul 26, 2017

Can some please explain why i am getting this Warning.

"Warning: Failed prop type: Invalid prop dateTime supplied to DateTimeField."
below is my code
i have taken date through props i.e Wed Jul 26 2017 13:15:00 GMT+0530 (IST)}


 const DateInput = props => {
  console.log(props);
  var date=props.date;
  return (
     <DateTimeField
      name="start_date"
      onChange={props.input.onChange}
      mode="date"
      dateTime={date}
      inputFormat='DD/MM/YYYY'
      format='DD/MM/YY'
    />
  );
};

and

 <Field
                name="start_date"
                className="form-control"
                type="text"
                component={DateInput}
                date={date}
              />

Thanks in Advance

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant