M
M
Marat Ivanov2021-05-26 19:54:58
React
Marat Ivanov, 2021-05-26 19:54:58

How to set start and end date in js calendar?

you need to get the start and end date for the allowed date range. Input field (react)

<Datepicker 
onChange => {this.handleChange}
value = {this.state.value}
restr = {this.restr}
/>
birthday accepts a prop that specifies the range of allowed birth dates in the form
restr = {start: new Date(2007,  4,  1), end: new Date(2010, 6, 20)}
. To exclude a birthday at which the user will be between 18 and 50 years old.
In other words, you need to get start and end for a user who is not less than 18, but not more than 50.
Please help me figure it out. Thanks everyone!

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question