Questions tagged [react-datetime]
50 questions
1
vote
1 answer
React-Datetime; I'm using two in one component, how do I tell which is which?
This is an odd question about react-datetime: Why doesn't the callback allow a "name" to be returned?
I'm using Daytime twice for "start" and "end" times on a calendar scheduler. But I want to use a single "onChange" event to update state. The…

Izzi
- 2,184
- 1
- 16
- 26
1
vote
1 answer
Setting state with the value of a react-dateTime component
please I need help. I'm using a react-dateTime component, and I am simply trying to get the value of that component just like every other field in a form. But I am unable to get the value of the selected date let alone store it in a state with the…

Martins
- 110
- 1
- 9
1
vote
1 answer
react-datetime with typescript TS2769 error
I am using react-datetime with a react typescript project. I got TS2769 compile eror"
TS2769: No overload matches this call.
Overload 1 of 2, '(props: Readonly): ReactDatetimeClass', gave the following error.
Type…

Jun Q
- 415
- 1
- 4
- 13
1
vote
1 answer
react-datetime timeConstraints for timePicker don't seem to work
I might be missing something here. react-datetime has a lot of functionality.
Out of the box the time picker allows you to choose HH MM AM/PM with a picker. I want to get rid of AM/PM, make the hours 0-23, and I want to be able to choose seconds…

Andrew W.
- 345
- 6
- 13
1
vote
0 answers
Mock moment functions in jest snapshot
I want to write a test for a react component using 'react-datetime' library. The component is using a lot of moment functions which I have to mock with jest one after another. I all the time get errors in the console while running test and keep…

heisenberg7584
- 563
- 2
- 10
- 30
1
vote
2 answers
How to enable manual range date time entering in react-datetime-range-picker?
What do i need to do enable manual date time entering? Because it's display as read only. but once set readOnly as false (input = {true}) it creates some errors
import React, { Component } from "react";
import DatetimeRangePicker from…

Oshini
- 613
- 4
- 17
1
vote
1 answer
how to render react datepicker properly without using npm?
here is my code, I can't use npm