Format value from input type=“datetime-local” for react-datetime
- Dominant language
- JavaScript
- Stars
- 2k
- Forks
- 858
- PR merge metrics
- No merged PRs in 30d
Description
### I'm Submitting a ...
```
[x] Bug report
[ ] Feature request
[x] Support request
```
### Steps to Reproduce
I need to use `input type='datetime-local'` in Datetime component, so I added `inputProps={{ type: 'datetime-local' }}` there. `input type='datetime-local'` needs to have some specific format for value like `yyyy-MM-ddThh:mm`, so I added `format` for date
```javascript
var date = moment().format('YYYY-MM-DDTHH:mm');
React.render(
,
document.body
);
```
There are no problems with choosing date, but when I'm trying to set time, I get some random date and can't choose any time at all.
### Expected Results
### Actual Results
### Minimal Reproduction of the Problem
I've tried to reproduce the problem, but there it doesn't work at all - it doesn't allow to choose any date or time.
[https://codepen.io/anon/pen/KRYEyZ](url)
### Other Information (e.g. stacktraces, related issues, suggestions how to fix)
Maybe it is possible to change format of value from `yyyy-MM-ddThh:mm` to `yyyy-MM-dd hh:mm` before passing it to calendar?
Contributor guide
Assessment
This issue has not been assessed yet.